A federal judge in San Francisco dealt a heavy blow to a landmark piece of President Joe Biden’s immigration policy Tuesday, calling his rule limiting who can claim asylum at the southern border «both substantive and procedurally invalid.»

Lawyers for the Department of Justice responded immediately by issuing a notice to appeal the decision in a higher court, and the case is likely to go all the way to the Supreme Court. The Biden administration is fighting to protect its «asylum ineligibility rule,» which requires asylum seekers to schedule an appointment for an asylum hearing at a legal port of entry or show they already applied for and were denied asylum in another country while en route to the US.

Judge Jon Tigar also stayed his own ruling for 14 days before it takes effect. The delay may keep the administration’s asylum policy in effect until the Supreme Court can rule.

The Biden administration rule has been in place since the Covid-19 restrictions known as Title 42 ended in May. Title 42 had blocked more than 2 million border crossings during its three years in force. Observers expected an increase in immigrants at the border after the end of Title 42, but the level of crossings actually fell, and the Biden administration argues that the asylum ineligibility policy has limited the number of immigrants crossing the border since May. He has argued in court that the asylum ineligibility policy is necessary to control migration during a «time of increased irregular migration throughout the Western Hemisphere.»

The government lawyers said the Department of Homeland Security anticipates that lifting the rule would mean «a return to elevated levels of encounters that would place significant pressure on the DHS component, border communities, and inland cities.»

In his opinion on Tuesday, Tigar said “[t]The rule, which has been in effect for two months, cannot remain in effect, and striking down the challenged rule would restore a regulatory regime that was in place decades earlier.»

Advocacy groups that sued the government to stop the rule from taking effect hailed the ruling, but said it was time to lift the asylum ineligibility rule.

Katrina Eiland, deputy director of the ACLU Immigrant Rights Project, who defended the case, said: «The ruling is a victory, but every day that the Biden administration drags out the fight over its illegal ban, many people fleeing persecution and seeking a safe haven for their families are placed in grave danger.»

Keren Zwick, director of litigation at the National Center for Immigrant Justice, He said: “American law protects the rights of people fleeing persecution to come to this country and seek asylum, period. We encourage the Biden administration to now direct its resources to defend that right, rather than fight to continue this illegal and inhumane asylum ban.»