The government backtracked on allowing America access to British bases to support the operation against the Iranian regime just hours before the UK base in Cyprus was hit by Tehran.
The government had previously not permitted the use of UK bases to support the attack on the dictatorship and its military infrastructure.
But the U-turn came after Britons in the region came under fire from Iranian strikes.
As the UK’s position developed over the weekend, the prime minister granted the US permission to use Diego Garcia, a joint military base in the Indian Ocean, and RAF Fairford in Gloucestershire for “defensive” purposes following legal advice.
The Telegraph revealed on Monday that Donald Trump had been “very disappointed” with Sir Keir Starmer for blocking him from using Diego Garcia for operations against Iran.
At the time of the Prime Minister’s statement on Sunday evening, an Iranian attack drone was on its way to RAF Akrotiri in Cyprus.
The attack, which took place at around midnight local time, caused "minimal damage" the MoD said.
In his statement Starmer said that allowing US access to British bases would enable it to carry out airstrikes for a “limited defensive purpose”.
He said: “The only way to stop the threat is to destroy the missiles at source – in their storage depots or the launchers which are used to fire the missiles. The US has requested permission to use British bases for that specific and limited defensive purpose.”
Starmer outlined the legal advice he has received.
“We have taken the decision to accept this request to prevent Iran firing missiles across the region, killing innocent civilians, putting British lives at risk and hitting countries that have not been involved.
“The basis of our decision is the collective self-defence of longstanding friends and allies, and protecting British lives. This is in line with international law and we are publishing a summary of our legal advice.”
The summary of the legal advice said that the support for the US was “solely focused on ending the threat of air and missile attacks against regional allies unlawfully attacked by Iran”.
It added that international law allows Britain to act in self-defence when it is the “only feasible means to deal with an ongoing armed attack”.
Donald Trump told the Telegraph that the Prime Minister’s initial refusal to let US forces use the Chagos Islands base was unlike anything that had “happened between our countries before”, adding that he was “very disappointed” in Sir Keir Starmer.
Trump said Sir Keir “took far too long” to change his mind.
“That’s probably never happened between our countries before. It sounds like he was worried about the legality.”
On Monday, Foreign Secretary Yvette Cooper said the decision was “about the defence of our partners in the Gulf and defence of countries where we have so many British citizens and interests”.
Some 200,000 Britons are believed to be in the Gulf at present, with more than 94,000 having registered their location and contact details to receive direct Foreign Office updates.
Cooper stressed that diplomacy had “always been” the preferred route for the government but that the UK would now help counter missile launches “pointed at the Gulf”.
She insisted British forces would not target “political and economic infrastructure”.
On Sunday, Defence Secretary John Healey refused six times to say whether Britain backed the original US-Israeli airstrikes.
“Britain played no part in the strikes on Iran. We share, however, the primary aim of all allies in the region and the US that Iran should never have a nuclear weapon,” he said.
Pressed on legality, he replied: “The straight answer to the question of ‘is the US action legal?’ That is for the US to set out and explain. It’s not for me as a defence secretary of the UK.”
But the government’s position has come in for criticism.
Lord Wolfson, the shadow attorney general, said that international law ought to provide a mechanism to “restrain and, if necessary, end” tyrannical regimes such as that in Iran.
“If the doctrines of international law prove unable to restrain Iranian terrorism and mass murder, and tie the hands of democracies while forcing them to stand and watch Iranian atrocities, international law will have failed,” he said.
While defending international law as a “just legal order,” he added that “too many international lawyers serenely promote an analysis which ultimately protects tyrants.”
He pointed to Iran’s enrichment of uranium to 60 per cent, its repeated threats against UK bases and personnel, and its plots on British soil.
In that context, he argued Britain had “three distinct legal bases to assist, militarily if necessary, its long-standing allies the US and Israel… to defend another member state pursuant to collective self-defence; to take proportionate action to avert continued Iranian attacks on the UK’s own bases and personnel; and/or to prevent Iran from implementing its clearly stated genocidal intentions against the people of Israel.”
He added that since the US and UK were “in the same legal position”, if the “UK cannot itself take offensive military action to support the US and Israel, the UK Government must also consider that the US strikes were unlawful.”
Echoing her legal adviser, Kemi Badenoch hit out at Starmer’s approach.
“We knew on Saturday that our allies in Canada and Australia had backed the action taken by the United States and Israel. Yet Keir Starmer still couldn’t tell the British people where our country stood or whether the UK would allow the use of our own airbases.
“It took Iranian missiles hitting allies in the Middle East and a UK base in Cyprus before Starmer finally approved the use of our bases, and this morning the Foreign Secretary still can’t say if the Labour government supports the action against Iran.
“Iran’s regime has funded international terrorism, attacked British nationals, brutally repressed its own citizens calling for freedom, and continues to try and develop a nuclear weapon. It should not be beyond our government to say they welcome the US-Israel taking action.”
She claimed a large bloc of Labour voters’ “political loyalties are swayed by conflicts in the Middle East, not the British national interest”. She added that Labour ministers “squirm and obfuscate in interviews, because they cannot say what needs to be said because too many of their voters do not want to hear it”.
Starmer has also been criticised by Reform UK for not supporting its allies sooner.
Nigel Farage said the UK decision to allow the use of its bases was “better late than never” and called on the Prime Minister to “support the Americans in this vital fight”.
Meanwhile, the Green Party leader Zack Polanski condemned what he described as “yet another Middle East illegal war”.
He called on the UK to sever ties with the US and appeared to blame Israel for the escalating tensions.
The London Assembly member wrote on social media: "This is an illegal, unprovoked and brutal attack that shows once again that the USA and Israel are rogue states.
"The UK must end our cosy relationship with the USA and our ongoing support for Israel."
He added: "There is only one nuclear armed state in the Middle East. It is Israel."
The Liberal Democrats have warned against the “slippery slope” of action and demanded MPs be given a vote on allowing US use of British bases.
Ed Davey said on Sunday that Starmer must come to Parliament and “set out the legal case in full and give MPs a vote.
"We have a duty to defend our brave British troops and citizens in the region, and that must be the focus of any operations. The UK must not be complicit in illegal military action,” Davey said.
To get more Politics news, click here to sign up for our free politics newsletter.
