By Bernd Debusmann Jr, BBC News, Washington
A court has frozen Texas's controversial immigration law, one of the toughest of its kind, in a case being closely watched across the US.
The legislation would allow officials in Texas to detain and prosecute anyone they think has entered the country illegally, superseding federal powers.
The law briefly came into force on Tuesday for a few hours during a legal back and forth between courts.
A US appeals court began hearing the case on Wednesday morning.
The SB4 law in Texas was due to come into effect on 5 March but President Joe Biden's administration challenged it on the grounds that immigrant detention should remain in its hands.
Migrant arrivals at the southern US border have risen to record highs during his administration, making it a top concern among US voters in the run up to November's presidential election.
That has led Texas to take stronger action on its border with Mexico and if the courts uphold its new law then other US states may follow.
Mexico has criticised the new law as anti-immigrant and has said it would refuse to accept anyone deported by Texas authorities.
Mexican President Andrés Manuel López Obrador called the law "draconian" and dehumanizing on Wednesday.
The decision to freeze the law is the latest in a string of judicial rulings deciding its fate.
Should it come back into effect, it would mark a significant shift in how immigration enforcement is handled, as courts have previously ruled that only the federal government can enforce the country's immigration laws - not individual US states.
Crossing the US border illegally is already a federal crime, but violations are usually handled as civil cases by the immigration court system.
Under SB4, anyone illegally entering or re-entering Texas faces up to 20 years in prison.
It is not clear if any migrants were detained while the law was in effect.
The ruling is the latest in a series of court rulings over whether SB4 can go ahead.
In January, the Biden administration sued the state of Texas and the following month a district court ruled that SB4 was illegal.
It blocked it from taking effect over concerns it would lead to each US state having its own immigration laws.
Soon after, the New Orleans-based US Court of Appeals for the Fifth Circuit - the federal appeals court responsible for the area - said the law may take effect as it considered the appeal, unless the Supreme Court intervened.
The Biden administration then filed an emergency request to the Supreme Court to uphold the district court's freeze while the litigation was under way.
In the meantime, Supreme Court Justice Samuel Alito placed a hold on the law to give the courts time to decide how it should proceed.
Earlier on Tuesday, the Supreme Court allowed the measure to take effect while a lower federal appeals court weighed its legality.
Then in a brief order late on Tuesday night, a three-judge panel at the Fifth Circuit voted to freeze the ruling as it hears the appeal.
Historically, the federal government has created laws and regulations on immigration, even though the US Constitution does not explicitly grant it those powers.
It is also the federal government that negotiates treaties and agreements with other countries.
Republicans often criticise Democratic President Biden's handling of the US-Mexico border, which opinion polls suggest is a prime concern for voters ahead of November's White House election.
A Gallup poll released in February suggested that nearly one-third of Americans believe immigration was the single greatest problem the country faced ahead of the government, the economy and inflation.
- This story was first published by the BBC