A spat over leaked memos from the UK's ambassador in Washington, Kim Darroch, has forced his resignation after Donald Trump refused to deal with him.
Britain's ambassador to Washington has quit after days of stinging criticism from Donald Trump, leading to accusations that Boris Johnson, the favourite to be the next British prime minister, had "thrown him under the bus".
Memos from Kim Darroch in which he described the Trump administration as inept were leaked to a British Sunday newspaper, infuriating the US president, who launched a Twitter attack on both the envoy and outgoing British Prime Minister Theresa May.
As the spat between the two allies intensified, Trump said he would no longer deal with the "very stupid" Darroch and called May "foolish".
Darroch said his position had become untenable.
The BBC's diplomatic correspondent said the ambassador had made the decision after Johnson declined to back him in a televised debate on Tuesday night.
Junior Foreign Office minister Alan Duncan was scathing of Johnson, who could become prime minister later this month if grassroots Conservatives elect him party leader.
"He has basically thrown this fantastic diplomat under the bus to serve his own personal interests," Duncan said.
"His sort of disregard for Sir Kim Darroch and his refusal to back him was, in my view, pretty contemptible."
In confidential memos dating from 2017 to the present, Darroch, 65, had said reports of in-fighting in the White House were "mostly true".
"We don't really believe this Administration is going to become substantially more normal; less dysfunctional; less unpredictable; less faction-riven; less diplomatically clumsy and inept," Darroch wrote in one cable.
It led to a scathing tirade from the US president.
"The wacky Ambassador that the UK foisted upon the United States is not someone we are thrilled with, a very stupid guy," he tweeted, describing Darroch as a "pompous fool".
Darroch had been due to step down at the end of the year.
"Since the leak of official documents from this Embassy there has been a great deal of speculation surrounding my position," he said.
"The current situation is making it impossible for me to carry out my role as I would like."
An inquiry is under way into who leaked the memos, and why.
British trade minister Liam Fox said their aim appeared to have been to hurt the two nations' relationship, or Darroch.
"Somebody has, for whatever malicious reasons, sought to either damage the UK-US relationship or indeed Sir Kim personally," he told reporters.
"I don't know what the motivations would be at this stage but it is very important that we find out who actually carried out this particularly damaging act."
Trump himself had previously suggested that leader of Britain's Brexit Party Nigel Farage would be a good choice as ambassador, irritating British officials.
Farage said this week he was not the right man for the job, but on Wednesday, after Darroch's resignation, he weighed in again.
"The right decision, time (to) put in a non-Remainer who wants a trade deal with America," Farrage tweeted.