WASHINGTON — House Speaker Paul Ryan, R-Wis., ended a monthlong holdout by formally backing his party's presumptive presidential nominee: Donald Trump.

On Thursday, the speaker penned a guest column for his hometown newspaper in which he trumpeted the controversial real estate mogul as someone who could support the speaker's conservative agenda. The move consolidated Trump's backing from Republican congressional leaders and most party leaders, leaving a small-but-influential bloc of conservatives who have vowed to never support him without a significant figurehead.

Like many senior Republicans, Ryan's endorsement came with its share of caveats about the speaker and the presumptive nominee's remaining policy differences. It did not signal any comfort with Trump's sometimes bombastic style compared to the values the speaker tries to embody.

Instead, Ryan's decision came down most squarely to attempting to prevent another Democrat from claiming the Oval Office.

“It's a question of how to move ahead on the ideas that I — and my House colleagues — have invested so much in through the years. It's not just a choice of two people, but of two visions for America,” Ryan wrote in the Janesville Gazette, citing the “bold” policy agenda that he will begin rolling out next week — and contrasting that with Democratic front-runner Hillary Clinton's platform.

“Donald Trump can help us make it a reality,” he said.

The move marks a big about-face for Ryan, who four weeks ago declared he was “not there yet” in terms of endorsing Trump and questioned whether the controversial businessman was even a conservative.

According to Ryan's team of advisers, the speaker made the decision to support Trump earlier this week — and by late Wednesday his senior staff began working on the op-ed for the Gazette in Janesville, Wis.

Ryan and Trump met once in person in mid-May when the billionaire crisscrossed Capitol Hill for meetings with House and Senate leaders. The speaker's advisers said they spoke by phone several other times, with the last call coming last week.

Neither side agreed to switch any policy positions, Ryan's advisers said, and one aide suggested that Thursday's endorsement should not be construed as the sort of “real unification” of Republicans that Ryan has called for repeatedly since first announcing he was not ready to endorse Trump.

Indeed, it's still not clear if Ryan will ever campaign side-by-side with Trump — his focus remains on helping elect House Republicans.

Ryan's move may signal that the speaker and other top Republicans are worried about keeping the House and Senate in Republican hands come November and believe the best way to do that is to unite the party.

Senate Majority Leader Mitch McConnell, R-Ky., was among the first top GOP leaders to publicly back Trump.

With his support, Ryan became the last senior Republican congressional leader to throw his weight behind Trump's candidacy. While the speaker did not use the word “endorse,” he tweeted that he would vote for his party's nominee in November. And Ryan's chief communications adviser, Brendan Buck, said reporters need not mince words to figure out what it all meant.

“We're not playing word games, feel free to call it an endorsement,” Buck tweeted.

Democrats pounced on the news and stressed their campaign strategy of tying Republican congressional candidates to Trump, who they argue is fatally unpopular with Latinos and women, among other important constituencies.

“House Republicans will be inseparably tied to their toxic front-runner in November, case closed,” said Democratic Congressional Campaign Committee spokeswoman Meredith Kelly. “Ryan's dragged-out decision underscores how truly vulnerable Donald Trump makes House Republicans in swing districts, but ultimately Ryan has only caused them further damage.”

Initially, the speaker was at odds with Trump's positions on key policy planks dear to mainstream Republicans of the past 40 years, including a free trade agenda and the effort to rein in federal spending on entitlements.

Those issues were the hallmark of Ryan's early congressional career, and Trump stands squarely against them.