WASHINGTON – The Supreme Court made it clear Monday that enforcing immigration laws is reserved for the federal government, not the states.

By an 8-1 vote, the justices rejected a request from Alabama to revive part of a 2011 law designed to drive out illegal immigrants. That year saw a wave of new laws in Republican-controlled states where lawmakers decried federal inaction. Alabama’s was deemed the toughest.

State officials said if federal authorities were not going to arrest illegal immigrants, their police would take on the task.

But the Obama administration went to court to challenge these laws, arguing that federal immigration policy trumped state efforts. The administration said it was targeting criminals, gang members and smugglers, not the millions of otherwise law-abiding but undocumented immigrants who live and work in this country.

The administration won a major victory last year when the Supreme Court struck down most of Arizona’s immigration enforcement law, known as SB 1070. In a 6-3 decision, the justices agreed that Washington, not the states, gets to decide how to enforce the immigration laws. The opinion rejected the idea that states could make immigration violations a crime under state law.

The high court upheld one provision that allows police to question people about their immigration status if they are stopped for some other lawful reason.

That ruling prompted the U.S. appeals court in Atlanta to block much of Alabama’s law, including a provision that made it a state crime to hide, harbor or transport illegal immigrants.

After considering the appeal in Alabama vs. United States for several weeks, the justices dismissed it on Monday. Justice Antonin Scalia dissented but did not write an opinion.

The court’s action is a setback for several states, including South Carolina, Utah and Georgia, which had adopted similar measures.