WASHINGTON — The inspector general of the Justice Department said Tuesday it’s “clear” that leading FBI officials wanted to stop Donald Trump from becoming president, but he insisted it didn’t affect the findings of their investigations.

Rep. Trey Gowdy (R-S.C.) opened a hearing of the House Oversight and Judiciary committees by reading anti-Trump text messages between Lisa Page and Peter Strzok — FBI officials who worked on the Hillary Clinton email and Russia probe cases.

“[Trump’s] not ever going to become president, right? Right?!” Page texted Strzok in 2016.

“No. No he won’t. We’ll stop it,” Strzok responded.

Gowdy asked Inspector General Michael Horowitz what Strzok meant by “it.”

“I think it’s clear from the context (the text means) ‘We’re going to stop him from becoming president,’” Horowitz said.

Gowdy asked Horowitz if he would have allowed anti-Trump staffers like Page and Strozk to keep working on an IG investigation.

“No,” he responded.

“This was extremely serious (and) completely antithetical to the core values and, my personal view having been a prosecutor and worked with FBI agents, I can’t imagine FBI agents suggesting even that they might use their powers to investigate frankly any candidate for any office,” Horowitz added.

But he stood by his conclusion that the “very troubling” positions by Page and Strzok — against Trump and in favor of Clinton — did not affect the outcome of the Clinton email investigation.

“We didn’t believe there was evidence to reach that conclusion (that bias turned into action),” Horowitz said.

“This is the conclusion of all of us in the IG … this is our team conclusion.”

But Gowdy wasn’t convinced.

“Bias is intrinsically harmful. It is the making up of your mind based on anything other than the facts,” Gowdy said. “We can survive with politicians we don’t trust. We can’t survive with a justice system we don’t trust.”

Democrats argued that every action by the FBI actually hurt Clinton and helped elect Trump.

“Why is it that, here and now, in June of 2018, we are still talking about Hillary Clinton’s emails at all?” asked Rep. Jerrold Nadler (D-NY). “I suspect it has something to do with the way Republicans have squandered their opportunity to govern, and the consequences of abdicating that responsibility.”