The revelation emerged in a blockbuster Senate intelligence committee hearing, one of the most significant moments yet in the saga over Russia's role in the 2016 election, the subsequent investigation and how it led to the firing of Comey by the President in an episode that has cast a deep shadow over the administration.
The former FBI chief warned in remarkable testimony that from the first time he met Trump he was worried that the President would misrepresent their conversations -- prompting him to write down everything that took place in meetings he found deeply uncomfortable. He accused the White House of lying about his leadership of the FBI and defaming him and called on Trump to release any tapes he may have of their conversations to provide corroboration.
But Republicans also seized on Comey's confirmation that he had indeed told Trump he was not personally under investigation in the Russia probe -- a fact that forms the bedrock of the defense case for Trump.
In one of the most revealing moments of the hearing, Comey said he had asked a friend at Columbia University to leak the content of one of his memos.
He said that it dawned on him that there could be corroboration of a memo that he wrote after the President tweeted that he better hope there were no White House tapes of their conversations.
"My judgment was that I needed to get that out into the public square," he said. He added he took the step "because I thought that might prompt the appointment of a special counsel."
Comey at one point told senators, "Lordy, I hope there are tapes."
Comey was asked by Arkansas Sen. Tom Cotton whether he believed that Trump had colluded with the Russians.
"It is a question I don't think I should answer in an open setting," Comey said, adding that the question would be answered by special counsel Robert Mueller's investigation.
Trump's lawyer read a statement responding to the Comey testimony
, highlighting the significance of the former FBI director explaining his leaking of the contents of his memos.
"Although Mr. Comey testified he only leaked the memos in response to a tweet, the public record reveals that The New York Times was quoting from these memos the day before the referenced tweet, which belies Mr. Comey's excuse for this unauthorized disclosure of privileged information and appears to entirely retaliatory," Marc Kasowitz said. "We will leave it the appropriate authorities to determine whether these leaks should be investigated along with all those others being investigated."
Kasowitz also accused Comey of misrepresenting the content of his conversations with Trump, disputing two key planks of his testimony.
He said the President never told Comey: "'I need loyalty, I expect loyalty' he never said it in form, he never said it in substance," Kasowitz said.
Kasowitz also disputed the notion that the President had asked Comey to stop investigating Flynn, saying that Trump "never, in form or substance, directed or suggested that Mr. Comey stop investigating anyone, including suggesting that that Mr. Comey 'let Flynn go.'"
Trump administration 'lies, plain and simple'
Comey also testified that the Trump administration "chose to defame me," told "lies, plain and simple," and that he was "confused" by Trump saying he was fired due to the Russia probe.
"The administration chose to defame me and, more importantly, the FBI by saying the organization was in disarray ... those were lies," Comey said.
However, he also said that he did not believe that either Trump nor his staff had asked him to stop the Russia investigation.
He told the committee that the "shifting explanations" from the White House for why Trump fired him last month "confused" and increasingly concerned him.
At the White House, deputy press secretary Sarah Huckabee Sanders pushed back on the idea that Trump was a liar.
"I can definitely say the President is not a liar, and I think it's frankly insulting that question would be asked," she said, pushing back on Comey's testimony that he was worried the President would not tell the truth about their meetings.
Comey also revealed new details about his meeting with Trump during the transition when he briefed the President-elect on details of a salacious dossier drawn up by a former British spy that suggested that Russia had incriminating information about him. Comey said he didn't want to create a "J. Edgar Hoover type situation" in which Trump concluded the bureau was trying to hold something over him. He said he was keen to leave the impression with Trump that the FBI was not investigating him.
Comey said he took exception to White House claims that the FBI was in disarray and that it was poorly led and had lost confidence in his leadership.
"Those were lies, plain and simple, and I am so sorry that the FBI workforce had to hear them, and I am so sorry that the American people were told them," Comey said.
Comey seized center stage in a compelling national political drama as he testified that as soon as he met the President-elect during the transition, he decided to create a written record of their meetings.
"I was honestly concerned that he might lie about the nature of our meeting," Comey said.
Comey said that he knew that one day he might need a written record of their conversations to defend himself and the FBI.
On Trump's tapes and leaking memos
Comey said that he believed it was his right to publicize the details of what he viewed were unclassified recollections of his conversation with Trump in his role as a private citizen.
He said he asked his friend to take the action rather than doing it himself because the press was camped outside his house and it would have been like feeding "seagulls at the beach."
He also revealed that he had now given all the memos to Mueller.
Comey said that he took the President's expression of "hope" that he could ease off of Flynn as a directive.
He said it rang in his ears as "will no one rid me of this meddlesome priest," paraphrasing a quote attributed to English King Henry II that courtiers took to mean he wanted the Archbishop of Canterbury Thomas Becket murdered in the year 1170.
Comey said that it had never occurred to him that there might be tapes of his conversations with Trump until the President tweeted about it.
And he called on Trump to make them public if tapes do exist.
"If he did, my feelings aren't hurt ... release all the tapes!"
Comey walked into the hearing room, wearing a dark suit and red tie, and sat impassively while a phalanx of press photographers crowded in front of him to take his picture. He sat alone at the witness table, facing the committee senators.
Republican Senate intelligence committee Chairman Richard Burr promised that the panel would establish the "facts separate from rampant speculation" and lay them before the American people so the nation could move on from the drama over alleged Russian interference in last year's election.
Trump's camp was reacting in real time to Comey's testimony, which was being carried on network television as well as streamed on multiple mobile devices in a rare moment of common national experience in the Internet age. An administration official said the President would monitor the hearings from a White House dining room in between meetings.
A person close to Trump's legal team said that the President "disputes ever saying that he wanted Comey's loyalty or to drop the case against Michael Flynn."
Early relationship to Trump
Comey also said that he was disturbed that the President repeatedly raised the issue of his wanting to keep his job and interpreted it as a sign that the President hoped to get something in return. He also revealed the words that Trump whispered in his ear, when the President summoned him across the room on camera at a reception at the White House shortly after the inauguration.
"What the President whispered in my ear was, 'I really look forward to working with you.'"
Comey related his sense of foreboding when he was asked by Trump to remain behind after after a wider meeting of White House and national security officials in the Oval Office.
"I knew something was about to happen, that I needed to pay very close attention to," Comey said, explaining why he decided to keep a close record of the meeting. He also said he believed that Attorney General Jeff Sessions knew that something significant was about to happen, and that Trump's son-in-law picked up on it too.
Republican Sen. Jim Risch of Idaho sought to water down the impact of Comey's testimony that Trump had told him that he hoped he would go easy on Flynn in the Russia investigation.
He stressed that according to Comey, Trump had said that he "hoped" for Flynn to be let go, and had not specifically ordered Comey to take that course.
But Comey replied that "I took it as this is what he wants me to do."
Comey's penchant for making a theatrical splash has already turned what was set to be a one-day drama into a two-day feeding frenzy, after he released his prepared opening statement Wednesday afternoon
, transfixing Washington.
Was there obstruction of justice?
Democrats highlighted one of the most stunning revelations of Comey's testimony, his statement that Trump asked him to halt the FBI probe into Flynn's conversations during the transition with Russia's ambassador to Washington.
He wrote that Trump said during a private meeting in the Oval Office: "'I hope you can see your way clear to letting this go, to letting Flynn go. He is a good guy. I hope you can let this go."
"I replied only that 'he is a good guy.'" Comey wrote, then added: "I did not say I would 'let this go.'"
Comey's account of this encounter conflicts with Trump's own statements. At a news conference May 18, the President was asked whether he had asked the FBI director to pull the plug on the Flynn component of the Russia investigation.
"No. No. Next question," Trump said.
Democrats believe the exchange between Trump and Comey about Flynn is more evidence that could build a case that the President obstructed justice -- which in several times in history has been regarded as an impeachable offense.
"I think it is devastating. ... If the President said those words, I believe it is absolutely devastating, completely inappropriate," said New Mexico Democratic Sen. Martin Heinrich, a member of the Senate intelligence committee, on CNN.
Comey testified that it was not up to him to say whether the conversations that he had with Trump amounted to an obstruction of justice.
"I don't think it's for me to say whether the conversation I had with the President was an effort to obstruct," Comey said, though he allowed that he was disturbed by the encounter in the Oval Office on February 14, in which the former FBI chief said that Trump had asked him to ease up on the probe into former national security adviser Michael Flynn.
CORRECTION: This story has been updated to correct the year of the Army-McCarthy hearings.