The court's decision comes days after the Obama administration issued a directive that protects from deportation hundreds of thousands of younger immigrants who came illegally to the United States as children. Obama on Monday used the court's decision to push for congressional action on a broader overhaul of immigration laws and to reaffirm his move to target deportations to criminals.
"I will work with anyone in Congress who's willing to make progress on comprehensive immigration reform that addresses our economic needs and security needs, and upholds our tradition as a nation of laws and a nation of immigrants," he said in a statement before leaving on a two-day campaign and fund-raising trip.
The decision keeps the issue of immigration as a high profile issue and gives Obama yet another opening to boost his standing with Hispanic voters for whom immigration is an important issue. Obama won two-thirds of the Latino vote in 2008 and has a large lead over Romney among that voting bloc in recent polls.
Obama pledged in 2008 to push for passage of comprehensive changes in immigration laws, but the effort stalled in Congress and Obama turned his attention to addressing the economy and pressed ahead with passing an overhaul of health care laws, which consumed much of 2010.
Romney on Monday blamed Obama for lack of action on immigration. He also said states have the right to secure their borders, "particularly when the federal government has failed to meet its responsibilities."
White House spokesman Jay Carney said efforts to deal with immigration have been hindered by "a retreat" among Republicans who had once advocated changes. He noted that Romney had embraced the Arizona law as a model for the country during the Republican primaries - a position, Carney said, "that hardly suggests a desire for comprehensive bipartisan immigration reform."
"This represents yet another broken promise by this president. I believe that each state has the duty - and the right - to secure our borders and preserve the rule of law, particularly when the federal government has failed to meet its responsibilities," Romney said in a written statement released before he left Salt Lake City on Monday morning to fly to a fund-raiser in Arizona.
Once in Scottsdale, a wealthy enclave outside Phoenix, he told donors: "I would have preferred to see the Supreme Court give more latitude to states, not less. And the states, now under this decision, have less authority, less latitude, to enforce immigration law."
Protesters greeted Romney in Scottsdale. The court's immigration ruling "leaves us with a bittersweet victory," said Carlos Galindo, an Obama supporter and the president of the Phoenix-area Immigrant Advocacy Foundation.
Earlier, Romney campaign spokesman Rick Gorka told reporters "the governor supports the states' rights to craft immigration laws when the federal government had failed to do so." He repeatedly declined to answer questions about whether Romney agreed with the ruling or whether the former Massachusetts governor would support the kind of laws the high court found mostly unconstitutional.
Romney has worked to soften his rhetoric on immigration policy since becoming the presumptive Republican nominee for president. During the Republican primary, Romney never endorsed Arizona's immigration law.
Asked in February during a GOP primary debate in Arizona whether he supported tough immigration enforcement that includes arrests, Romney said: "I think you see a model in Arizona." He then mentioned the federal E-Verify program that requires businesses to check the legal status of their employees as one way to reduce the number of illegal immigrants in a particular state.
Romney then addressed the Arizona law: "So going back to the question that was asked, the right course for America is to drop these lawsuits against Arizona and other states that are trying to do the job Barack Obama isn't doing," he said.
Arizona officials, meanwhile, were expressing some satifaction after the ruling. Gov. Jan Brewer called the decision a victory for all Americans, saying that the law could now be enforced and that any officers who violate a person's civil rights will be held accountable.
Immigration-rights groups said they were surprised and disappointed by the court's decision, and planned to ask the lower courts to block implementation of the surviving part of the law.
"The opinion invites the challenges that we are bringing. It's going to cause racial profiling. It will cause prolonged detentions," said Linton Joaquin of the National Immigration Law Center, one of the groups pushing a separate challenge to the Arizona law.
Kansas attorney Kris Kobach, who helped draft the Arizona law and has advised officials in other states wanting to crack down on illegal immigration, called the ruling "a big victory for Arizona" while acknowledging that "it's not a complete victory."
Arizona has spent almost $3 million defending the law for the last two years, the Arizona Republic reported Monday.