Britain's spy agency did not eavesdrop on US President Donald Trump during the 2016 campaign, a British security official has said.

It follows a claim made on Fox News in which it was asserted the UK Government Headquarters (GCHQ) spied on Trump on behalf of former president Barack Obama.

By using the British spy agency, it was claimed that Obama was able to bypass the NSA, the CIA and the FBI without leaving a footprint.

However, a security official, who is familiar with British government policy and security operations, told Reuters such claims were "totally untrue and quite frankly absurd".

It was more likely that the unsubstantiated claim was an attempt to defend Trump's tweets, which allege Obama was spying on Trump Towers – also without providing evidence.

Judge Andrew Napolitano, now an analyst at Fox News, made the accusations while appearing on Fox and Friends on Tuesday (14 March).

"Three intelligence sources have informed Fox News that President Obama went outside the chain of command," Napolitano said.

"He didn't use the NSA, he didn't use the CIA, he didn't use the FBI, and he didn't use the Department of Justice."

Instead, Napolitano said, Obama used GCHQ.

"There's no American fingerprints on this," Napolitano said. "What happened to the guy who ordered this? Resigned three days after Donald Trump was inaugurated."

Napolitano was referring to former GCHQ director Robert Hannigan who resigned on 23 January after two years in the job, however all reports suggest he is leaving for personal reasons and not due to any disciplinary matter.

Hannigan will also remain as head of the agency until a replacement is found.

USA-TRUMP/HEALTHCARE
US President Donald Trump has been outspoken about unsubstantiated 'wiretapping' claims Reuters/Kevin Lamarque

Disputing the claim, the security official told Reuters that under British law, GCHQ "can only gather intelligence for national security purposes" and noted that the US election "clearly doesn't meet that criteria."

The official added that GCHQ "can only carry out intelligence operations where it is legal in both the US and UK to do so." GCHQ declined to comment.