LONDON- A "technical error" led to parts of a message congratulating U.S. President Donald Trump being left visible in an official tweet congratulating Joe Biden from British Prime Minister Boris Johnson, a government spokesman said on Tuesday.

He said the government had prepared two different statements because the contest was so close, but that a technical error meant parts of the alternative message were embedded in the background of the graphic congratulating Biden.

Earlier on Tuesday, the Guido Fawkes website published a picture of the tweet after it had adjusted the contrast and brightness levels of the image. It appeared to show Trump's name, the words "second term" and "on the future of this" in the background of the tweet congratulating Biden.

"As you'd expect, two statements were prepared in advance for the outcome of this closely contested election. A technical error meant that parts of the alternative message were embedded in the background of the graphic," a government spokesman said.

(Reporting by Elizabeth Piper; editing by Michael Holden) ((elizabeth.piper@thomsonreuters.com; 07979746994; Reuters Messaging: elizabeth.piper.thomsonreuters.com@reuters.net))