The Supreme Court ruled Thursday in a 5-4 decision that the Biden administration can repeal the Trump administration’s Migrant Protection Protocols, commonly known as the "Remain in Mexico" policy, reversing a lower court ruling.

Under that policy, migrants seeking entry into the U.S. had to stay in Mexico as they awaited hearings. The Trump administration put the policy in place so that migrants would not be released into the U.S. The Biden administration had tried to repeal the policy but was previously blocked by a lower court. At issue was whether the Department of Homeland Security's suspension and subsequent termination of the policy violated a federal law that requires that migrants be detained or, if they arrived from a contiguous country, sent back.

"[T]he Government’s rescission of MPP did not violate section 1225 of the INA [Immigration and Nationality Act], and the October 29 Memoranda did constitute final agency action," Chief Justice John Roberts wrote in the Court's opinion.

The statute Roberts cited, 8 U.S.C. Section 1225, says that someone applying for admission "shall be detained for a proceeding" unless they are "clearly and beyond a doubt entitled to be admitted," and also says if they are from a contiguous territory like Mexico, "the Attorney General may return the alien to that territory" as they await a hearing. Texas and Missouri had pointed to this language in arguing that the Remain in Mexico policy was necessary to adhere to this law. Without the ability to detain everyone, the states argued in their lawsuit, sending them back when possible is necessary. 

SUPREME COURT JUSTICES HEAR ARGUMENTS OVER ‘REMAIN IN MEXICO’ BORDER POLICY

The court's majority pointed to the language in the law that says the government "may return" migrants to a contiguous territory, noting the "discretionary" nature of the wording. While all sides agreed on that, it was the states' interpretation – and that of a lower court ruling -- that a return is required if a person is not detained that the court disputed.

"The problem is that the statute does not say anything like that," Roberts wrote in his opinion, in which he was joined by Justices Stephen Breyer, Sonia Sotomayor, Elena Kagan and Brett Kavanaugh. Roberts explained that had Congress meant for a return to be mandatory in the event that there was a lack of compliance with the detention requirement, it would have said so in clear language.

JUSTICE CLARENCE THOMAS WON'T BE FIRED FROM GEORGE WASHINGTON UNIVERSITY DESPITE STUDENT OUTRAGE

"The statutory grant of discretion here contains no such caveat, and we will not rewrite it to include one," Roberts wrote.

The court also pointed to "the foreign affairs consequences" of requiring a return, pointing to how the Constitution only authorizes the Executive Branch to handle "direct diplomacy" with other countries, and how the lower court's ruling against the Biden administration would have "imposed a significant burden upon the Executive’s ability to conduct diplomatic relations with Mexico."

The court argued that the Return to Mexico policy "applies exclusively to non-Mexican nationals who have arrived at ports of entry that are located 'in the United States,'" and that therefore the Executive Branch "cannot unilaterally return these migrants to Mexico." Roberts cited a Biden administration claim that the policy has negatively impacted other areas of relations with Mexico.

"Yet under the Court of Appeals’ interpretation, section 1225(b)(2)(C) authorized the District Court to force the Executive to the bargaining table with Mexico, over a policy that both countries wish to terminate, and to supervise its continuing negotiations with Mexico to ensure that they are conducted ‘in good faith,’" Roberts wrote. "That stark consequence confirms our conclusion that Congress did not intend section 1225(b)(2)(C) to tie the hands of the Executive in this manner."

The court also noted that Congress gave the Department of Homeland Security the discretion to utilize a third option for migrants, which is parole.

"Every administration, including the Trump and Biden administrations, has utilized this authority to some extent," the court said.

Ruling that repealing the Remain in Mexico policy does not violate the Immigration and Nationality Act, the Supreme Court said the lower court should now look for the first time at whether the Biden administration's Oct. 29, 2021 memo terminating the policy was in compliance with Administrative Procedure Act protocols that govern the actions of federal agencies.

Justice Kavanaugh, in a concurring opinion, also referenced the parole option, stating that both parole and return "are legally permissible options," meaning that the Return to Mexico policy is not mandatory.

SUPREME COURT DEALS BIDEN CLIMATE AGENDA SERIOUS BLOW WITH EPA DECISION

Justice Barrett, in a dissenting opinion, said she agreed with the majority's view of the relevant immigration law, but believed that the court's opinion in a separate case issued two weeks ago impacted the issue of whether lower courts had the jurisdiction to hear the case in the first place. Instead of ruling on the case, she argued, the Supreme Court should have sent the case back down for the lower court to consider the recent decision.

"I agree with the Court’s analysis of the merits—but not with its decision to reach them," Barrett wrote.

In a more contentious dissent, Justice Samuel Alito – joined by Justices Clarence Thomas and Neil Gorsuch – argued that the government does not have the authority to release migrants into the U.S. if it is believed that they are not eligible for admission.

"When it appears that one of these aliens is not admissible, may the Government simply release the alien in this country and hope that the alien will show up for the hearing at which his or her entitlement to remain will be decided? Congress has provided a clear answer to that question, and the answer is no," Alito wrote, citing statutory language that in such a case, a migrant "shall be detained" for either removal or consideration of an asylum application.

While Alito acknowledged – as Roberts and Kavanaugh had – that returning a migrant who came from a contiguous territory is only one alternative along with parole, he cited a separate law that said parole is only to be used "on a case-by-case basis for urgent humanitarian reasons or a significant public benefit."

CLICK HERE TO GET THE FOX NEWS APP

"Due to the huge numbers of aliens who attempt to enter illegally from Mexico, DHS does not have the capacity to detain all inadmissible aliens encountered at the border, and no one suggests that DHS must do the impossible," Alito wrote. "But rather than avail itself of Congress’s clear statutory alternative to return inadmissible aliens to Mexico while they await proceedings in this country, DHS has concluded that it may forgo that option altogether and instead simply release into this country untold numbers of aliens who are very likely to be removed if they show up for their removal hearings."

"This practice," Alito continued, "violates the clear terms of the law, but the Court looks the other way."