Maz Saleem of campaign group Stand Up to Trump welcomed the news, saying: “It is a victory for the millions who oppose the president’s racism, his addiction to war, his sexism and his billionaire’s contempt for ordinary people.

“It is proof that protest can prevail and that the most powerful world players can be faced down. We will continue to build the widest possible co-ordination against a future visit in the confidence that we can win again.”

Labour’s Mr Khan argued that the real reason the US president had pulled out of the planned visit was that he had “got the message” that Londoners oppose his bigoted policies and actions.

“This just reinforces what a mistake it was for Theresa May to rush and extend an invitation of a state visit in the first place,” the London mayor added.

Foreign Secretary Boris Johnson attacked Mr Khan’s comments in a Twitter outburst, writing: “We will not allow US-UK relations to be endangered by some puffed-up pompous popinjay in City Hall.”

Meanwhile, Mr Trump was roundly criticised for his racist slurs against Haiti and “shithole countries” in Africa.

He denied using such language, but a senator present at the meeting, at which Mr Trump rejected a bipartisan immigration deal, said “shitholes” was “the exact word used … not just once but repeatedly.”

The African Union said it was “frankly alarmed,” particularly “given the historical reality of how many Africans arrived in the United States as slaves.”