The roots of the Republican crackup this fall that paralyzed the House, fueled the unexpected rise of Speaker Mike Johnson and now threatens to force a government shutdown crisis early next year lie in a fateful choice the party made more than a decade ago that has come back to haunt its leaders.

In early 2009, congressional Republicans were staring down a long exile in the political wilderness. Barack Obama was about to assume the presidency, and Democrats were within reach of a filibuster-proof, 60-vote supermajority in the Senate and the largest House majority in more than 20 years after the economic crisis of 2008.

But Republicans saw a glimmer of hope in the energized far-right populist movement that emerged out of a backlash to Mr. Obama — the first Black president — and his party’s aggressive economic and social agenda, which included a federal health care plan. Republicans seized on the Tea Party and associated groups, with their nativist leanings and vehemently anti-establishment impulses, as their ticket back to power.

“We benefited from the anger that was generated against the one-way legislation of the Obama years,” said Eric Cantor, the former House leader from Virginia who became the No. 2 Republican after the 2010 midterm elections catapulted the party back into the majority. “It was my way or the highway.”

Mr. Cantor and his fairly conventional leadership team of anti-tax, pro-business Republicans set out to harness that rage to achieve their party’s longstanding aims. But instead, the movement consumed them.

Within four years, Mr. Cantor was knocked out in a shocking primary upset by a Tea Party-backed candidate who had campaigned as an anti-immigration hard-liner bent on toppling the political establishment. It was a sign of what was to come for more mainstream Republicans.

“We decided the anger was going to be about fiscal discipline and transforming Medicare into a defined contribution program,” Mr. Cantor said recently. “But it turned out it was really just anger — anger toward Washington — and it wasn’t so policy-based.”

The forces that toppled Mr. Cantor — and three successive Republican speakers — reached their inexorable conclusion last month with the election of Mr. Johnson as speaker, cementing a far-right takeover that began in those first months after Mr. Obama took office.

Mr. Johnson, who identifies as an archconservative, is the natural heir to the political tumult that began with the Tea Party before evolving into Trumpism. It is now embodied in its purest form by the Freedom Caucus, the uncompromising group of conservatives who have tied up the House with their demands for steep spending cuts. And the situation won’t get any easier when Congress returns from its Thanksgiving respite to confront its unsettled spending issues and what to do about assistance to Israel and Ukraine.

The ranks of more traditional Republicans have been significantly thinned after the far right turned on them in successive election cycles. They have been driven out of Congress in frustration or knocked out in primaries, which have become the decisive contests in the nation’s heavily gerrymandered House districts.

“They thought they could control it,” Michael Podhorzer, the former political director of the A.F.L.-C.I.O. who has studied the House’s far-right progression, said of G.O.P. leaders. “But once you agree essentially that Democrats are satanic, there is no room in the party for someone who says we need to compromise with Democrats to accomplish what we need to get done.”

The result, Mr. Podhorzer said, is a Republican majority that his research shows across various data points to be more extreme, more evangelical Christian and less experienced in governing than in the past. Those characteristics have been evident as House Republicans have spent much of the year in chaos.

“It isn’t that they are really clever at how they crash the institution,” Mr. Podhorzer said. “They just don’t know how to drive.”

From the start, members who were more rooted in the traditional G.O.P., which had managed to win back the House majority in 1994 after 40 years, struggled to mesh with the Tea Party movement, which was driven to upend the status quo. Many top Republicans had voted for the bank bailout of 2008, a disqualifying capital crime in the eyes of the far-right activists.

Leading congressional Republicans were leery of the Tea Party’s thinly veiled racism, illustrated by insulting references to Mr. Obama and the questioning of his birthplace, though they said they saw the activists as mainly motivated by an anti-tax, anti-government fervor.

Traditional Republicans appeared at Tea Party rallies where they were barely tolerated, while the far-right Representatives Michele Bachmann of Minnesota and Steve King of Iowa, then outliers in the party, were the stars. They tried to mollify activists with tough talk on taxes and beating back the Obama agenda, but saw mixed results.

The Republican National Committee also sought to align itself with the Tea Party, encouraging angry voters to send virtual tea bags to Congress in a 2009 Tax Day protest. Tea Party activists rebuked the national party, saying it hadn’t earned the right to the tea bag message.

But the Tea Party paid huge electoral benefits to the House G.O.P. in 2010, as it swept out Democrats and swept in scores of relatively unknown far-right conservatives, some of whom would scorn their own leaders as much as the Democrats. The steady march to the modern House Republican Conference had begun.

“It truly was bottom up,” said Doug Heye, a Republican strategist who was then the spokesman for the R.N.C. “Then how do you have control over that? When you have that big a win, you are going to have people who just aren’t on your radar screen, but if they were, you would have tried to prevent them from winning their primary.”

In the Senate, the Tea Party was having a different effect. Far-right conservatives such as Sharron Angle in Nevada and Christine O’Donnell in Delaware managed to prevail in their primaries, only to lose in the general election. That cost Senate Republicans a chance to win a majority in that chamber. The extreme right has had less influence in the Senate than the House ever since.

The ramifications of the far-right bargain for congressional Republicans quickly became clear. Mr. Cantor was defeated in 2014, and Speaker John A. Boehner, dogged by hard-line conservatives he branded “knuckleheads,” resigned in 2015. In 2018, Speaker Paul D. Ryan, Mr. Boehner’s successor and the party’s vice-presidential nominee in 2012, had his fill of clashes with President Donald J. Trump — who aligned himself with the Tea Party in its early days — and chose not to run for re-election.

Then Representative Kevin McCarthy — the last of a trio called the “Young Guns,” with Mr. Cantor and Mr. Ryan, that once seemed to be the future of the party — fell from the speakership in October. That ended the reign of House Republican speakers who had tried unsuccessfully to weaponize the ultraconservatives in their ranks while holding them at arm’s length.

Mr. McCarthy’s ouster cleared the way for Mr. Johnson, who was chosen only after House Republicans rejected more established leaders, Representatives Steve Scalise of Louisiana and Tom Emmer of Minnesota, who would have easily ascended in the previous era.

Despite his unquestioned conservative bona fides, Mr. Johnson is already encountering difficulties in managing the most extreme element within his ranks.

Last week, Freedom Caucus members blocked a spending measure in protest of Mr. Johnson’s decision to team with Democrats to push through a stopgap funding bill to avert a government shutdown.

The move underscored the far-right’s antipathy to compromise and the dominance it now enjoys in the House, and raised the prospect that Mr. Johnson could face another rebellion if he strays again.