FBI Director James Comey says he believed it would have been "catastrophic" to keep Congress in the dark about new developments in the Hillary Clinton email investigation that emerged close to Election Day.
Mr Comey, in the most impassioned and public defence of how he handled this case, also said it made him feel "mildly nauseous" to think his actions in October could have influenced the race won by Republican Donald Trump over Democrat Ms Clinton.
But he told the Senate Judiciary Committee that the FBI cannot take into account how its actions might benefit or harm politicians.
"I can’t consider for a second whose political futures will be affected and in what way," Mr Comey said.
"We have to ask ourselves what is the right thing to do and then do it."
Speaking at times with a raised voice, Mr Comey said he faced two difficult decisions when agents told him they found emails potentially connected to the Clinton case on a laptop belonging to former Rep Anthony Weiner, who was married to close Clinton aide Huma Abedin.
Mr Comey said he knew it was unorthodox to alert Congress to that discovery 11 days before Americans picked a new president.
But he said he decided it would have been "catastrophic" to keep silent, especially when he had testified under oath that the investigation had been concluded.
"I sat there that morning and could not see a door labelled, ’No action here’," Mr Comey said.
FBI Director James Comey: "It makes me mildly nauseous to think that we might have had some impact on the election." https://t.co/9361xp3gCL— CNN (@CNN) May 3, 2017
Later, the top Democrat on the House intelligence committee said Mr Comey's explanation for why he disclosed details about the email investigation is a "poor characterisation" of the choice.
Rep Adam Schiff, of California, said Mr Comey's decisions to talk publicly about the Clinton probe and not say anything about the Trump investigation was a violation of FBI policy.