Washington: The US Department of Homeland Security announced Monday night it will end a Trump-era policy requiring asylum-seekers to wait in Mexico while their applications play out in court.

The DHS announcement comes hours after a judge lifted an injunction that had prevented US President Joe Biden's administration from ending the so-called "Remain in Mexico" policy.

Under the policy, instituted in 2019 under former president Donald Trump, tens of thousands of asylum-seekers were sent across the border until required to appear in the United States for their immigration hearings.

Critics called the program cruel and dangerous, with vulnerable people placed in insecure conditions in border towns.

The policy will be rolled back "in a quick, and orderly, manner," the department wrote in a statement.

No one else will be enrolled and those who cross the border for their court dates will no longer be sent back to Mexico afterwards, DHS added.

The Migrant Protection Protocols (MPP), as the policy is officially called, "has endemic flaws, imposes unjustifiable human costs, and pulls resources and personnel away from other priority efforts to secure our border," DHS said.

Soon after taking office, Biden attempted to end the border measure as part of what he called a more humane approach to immigration.

But a group of Republican-governed states led by Texas sued the administration and a US District Court ordered the policy to be reinstated.

The case eventually ended up before the Supreme Court, which ruled on June 30 that Biden had the authority to end the program.

From the start of the policy in January 2019 until its initial suspension under Biden, at least 70,000 people were sent back to Mexico, according to the American Immigration Council.

The Trump administration had argued the approach was needed to stem illegal immigration to the United States.

During Biden's tenure, more than 200,000 people attempting to enter the country illegally have been stopped at the border each month and sent back, either under MPP or a separate, Covid-related policy blocking people at the border.