At 6:42 a.m., Mr. Trump tweeted that “sick and demented people who were in the sights of Scotland Yard” carried out the attack, which injured at least 29 people in the blast and ensuing panic. It was not clear where Mr. Trump got that information, though 23 minutes earlier, “Fox & Friends,” a program he regularly watches, broadcast a report in which a security analyst said he feared that the London police had already known the identity of the attackers.
“Can someone tell Scotland Yard?” asked Brian Kilmeade, one of the hosts of the program.
White House officials tried to play down the contretemps, saying Mr. Trump was referring to the longstanding efforts of British law enforcement authorities to investigate would-be terrorists, not to anyone involved in Friday’s attack.
“What the president was communicating is that obviously all of our law enforcement efforts are focused on this terrorist threat for years,” said the national security adviser, Lt. Gen. H. R. McMaster. “Scotland Yard has been a leader, as our F.B.I. has been a leader.”
The press secretary, Sarah Huckabee Sanders, said she believed that Mr. Trump’s tweet had come up in the conversation with Mrs. May, though she did not characterize the exchange. Mr. Trump, for his part, referred to Mrs. May as “a wonderful woman.” But Mrs. May made her displeasure clear earlier in the day when she told reporters, “I never think it’s helpful for anybody to speculate on what is an ongoing investigation.”
Others were more scathing. Mrs. May’s former chief of staff, Nick Timothy, wrote on Twitter, “True or not — and I’m sure he doesn’t know — this is so unhelpful from leader of our ally and intelligence partner.”
The president has had a strained relationship with Britain since before he took office. Soon after he was elected, he suggested that Nigel Farage, a leader of Britain’s movement to leave the European Union, should be made the British ambassador to the United States — a decision that, London pointed out, was not Mr. Trump’s to make.
Mrs. May and Mr. Trump have had an awkward relationship, going back to their first meeting, when people criticized the way he gripped her hand. Last month, she joined other world leaders in criticizing his response to the white supremacist violence in Charlottesville, Va.
For Mr. Trump, the news of another terrorist attack also offered a moment to do some political repositioning by returning to themes that have…