A trial court had previously said the money could not be switched from the Pentagon towards construction of a wall on the US-Mexico border, one of the president’s repeated policy promises to supporters. An appeals court had also refused to enter a stay while the matter was considered.

But on Friday, the nation’s highest court entered such a stay, and permitted constriction to continue while litigation over the issue played out.

The court’s decision handed a big victory to the president, which he was quick to embrace.

“Wow! Big VICTORY on the Wall,” he tweeted. “The United States Supreme Court overturns lower court injunction, allows Southern Border Wall to proceed. Big WIN for Border Security and the Rule of Law!”

Trump prototypes for Mexico border wall demolished in California Show all 20 1 /20 Trump prototypes for Mexico border wall demolished in California Trump prototypes for Mexico border wall demolished in California The prototypes for President Trump’s border wall are being demolished. AP Trump prototypes for Mexico border wall demolished in California The US Customs and Border protection had built the eight 30-foot tall steel and concrete models near San Diego on the US-Mexico border. Reuters Trump prototypes for Mexico border wall demolished in California A 2018 report from the Government Accountability Office found that the construction challenges presented by the four concrete models would be “extensive” and those presented by two of the other models would be “substantial”. Reuters Trump prototypes for Mexico border wall demolished in California It was intended that Mr Trump would choose his favourite of the designs after testing had been completed. AFP/Getty Trump prototypes for Mexico border wall demolished in California The President is yet to comment. AFP/Getty Trump prototypes for Mexico border wall demolished in California Each prototype cost $300,000 to $500,000 to build and they are being knocked down in order to make way for the San Diego Secondary Wall project which will see up to 14 miles of barrier being built to support the existing steel border fence. AP Trump prototypes for Mexico border wall demolished in California The new barrier will not employ the design of any of the prototypes, instead being built of the favoured steel bollards which make up the current section of the wall at San Diego. Reuters Trump prototypes for Mexico border wall demolished in California The new secondary barrier being built near San Diego. Reuters Trump prototypes for Mexico border wall demolished in California The rubble of one of the demolished prototypes. Reuters Trump prototypes for Mexico border wall demolished in California A steel wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A wall prototype made from a mix of steel and concrete AFP/Getty Trump prototypes for Mexico border wall demolished in California A wall prototype made from a mix of steel and concrete AFP/Getty Trump prototypes for Mexico border wall demolished in California A concrete wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A steel wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A concrete wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A concrete wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A concrete wall prototype AFP/Getty Trump prototypes for Mexico border wall demolished in California A digger approaches the prototype wall AFP/Getty Trump prototypes for Mexico border wall demolished in California Aerial view of the wall prototypes at the US-Mexico border after they were torn down AFP/Getty Trump prototypes for Mexico border wall demolished in California An aerial view showing Tijuana, Mexico on the left and the demolished wall prototypes on the right AFP/Getty

The 5-4 decision by the court came on ideological lines. Its four most liberal justices dissented the decision.

Earlier this year, having failed to obtain more than $6bn in funding for a wall despite shutting down the government for 35 days – the longest shutdown in US history – the president announced he was declaring an emergency at the country’s border with Mexico.

By doing so, he hoped to obtain the funds without the approval of Congress, a tactic many critics – as well as members of his own party – believed overstepped the constitutional powers of the presidency.

Trump says border wall would have prevented father and daughter from drowning in Rio Grande

The case in court arose from a challenge to Mr Trump’s action brought by Sierra Club, a leading environmental group, and the Southern Border Communities Coalition, a group advocating for people living in border areas.

The challengers had said the wall would be disruptive to the environment, partly because it could worsen flooding problems and have a negative impact on wildlife.

US district Judge Haywood Gilliam ruled on May 30 in Oakland, California, that the administration’s proposal to build parts of the border wall in California, New Mexico and Arizona with money appropriated for the defence department to use in the fight against illegal drugs, was unlawful. The judge issued an injunction barring use of the Pentagon funds for a border wall.

The Supreme Court said on Friday that it would lift a freeze on the money put in place by the lower court and its actions mean the administration can make use of the funds to begin work on four contracts it has already awarded.

The American Civil Liberties Union (ACLU), which represented the groups challenging the administration, vowed to fight on.

“This is not over. We will be asking the federal appeals court to expedite the ongoing appeals proceeding to halt the irreversible and imminent damage from Trump’s border wall,” said ACLU lawyerDror Ladin.