As President Trump bowed to bipartisan pressure and walked back his dismissal of Russian election interference, one Republican senator was still taking shots at his critics, calling those who questioned Trump’s efforts to build a relationship with Russian President Vladi­mir Putin “unhinged” and “crazy.”

“That’s the sort of thing we should be doing,” Sen. Rand Paul (R-Ky.) told reporters on Tuesday, dismissing those disapproving of Trump’s handling of Monday’s summit with Putin — House Speaker Paul D. Ryan (R-Wis.) and war hero Sen. John McCain (R-Ariz.) among them — as “people who hate the president.”

Paul spent the last few days as one of a handful of voices in Congress praising Trump for a controversial summit in which the president suggested he was inclined to believe Putin’s denial that Russia had interfered in the 2016 U.S. presidential election over the conclusions of U.S. intelligence.

“Any country that can spy does, and any country that can meddle in foreign elections does,” Paul said on CNN on Monday. “All countries are doing this, but we’ve elevated this to a higher degree. . . . It’s all about partisan politics now. This is truly the Trump derangement syndrome that motivates all of this.”

His words did not go unnoticed by the president, who tweeted thanks to Paul on Tuesday morning for his defense of the summit with Putin and his commentary on Russian interference — and his continued insistence that the investigations into it have not shown any collusion between Trump and the Kremlin.

In a GOP that is still largely hawkish, Trump, who has questioned the value of traditional alliances, and Paul, whom McCain once accused of “working for Vladi­mir Putin” for opposing Monte­negro’s bid to join NATO, often embrace similarly noninterventionist worldviews. On the presidential campaign trail, both Paul and Trump advocated scaling back foreign aid, staying out of the war in Syria and engaging in direct diplomacy with Putin. This week, Paul announced in an op-ed in Politico that he would soon be making a trip to Russia to “discuss common ground with their leaders” — and would be consulting with the president before going. That trip takes place in three weeks, a spokesman for Paul said Tuesday.

But Trump and Paul have not always had such a warm relationship. As presidential candidates, Paul questioned the “sophomoric quality” of Trump’s temperament, comparing his tendency to attack people’s looks and character to what “happened in junior high,” and questioning whether that made him unfit to be commander in chief.

“Do we want someone with that kind of character, that kind of careless language to be negotiating with Putin?” Paul asked during a September 2015 Republican primary debate.“Would we not all be worried to have someone like that in charge of the nuclear arsenal?”

Their relationship soured further last year, when Trump took the advice of his national security advisers and decided to commit more resources and time to the war in Afghanistan, launch strikes against government targets in Syria, and step up defense spending to unprecedented levels. Such disagreements led them into direct conflict as well, as Paul last year pushed an effort to block part of a massive arms sale to Saudi Arabia over the humanitarian tragedy in Yemen, and slow progress on the defense bill by campaigning to impose an expiration date on the existing authorizations for use of military force.

Earlier this year, Paul even threatened to withhold his support for secretary of state nominee Mike Pompeo over the Trump administration’s Afghanistan policy — prompting the president to launch a personal appeal to the Kentucky Republican to prevent Pompeo from being the first secretary in over a century to fail to get the Senate Foreign Relations Committee’s backing.

Paul changed his mind — and the nature of the Trump-Paul relationship also appeared to turn a corner.

By this week, as nearly every top-ranking Republican was lecturing or excoriating the president for refusing to prioritize U.S. interests and the conclusions of the intelligence community over his personal affinity for Putin, Paul was equivocating between Russia and American interference, praising the president on PBS for expressing a “healthy dose of skepticism” about the U.S. intelligence community’s conclusions, and taking it upon himself to undermine Trump’s fiercer critics online.

On Monday, former CIA director John Brennan tweeted that Trump’s Helsinki news conference commentary was “treasonous” and akin to “high crimes & misdemeanors.”

Paul shot back, pointing out Brennan had voted for the Communist Party candidate in 1976.

Robert Costa contributed to this report.