Mr. Boehner’s decision is likely to smooth a short-term path around a government shutdown at the end of the month. But the real showdown looms on Dec. 11, when a stopgap spending bill expected to pass this week would expire, meaning Congress and the president would have to find a way to fund the government through next September and raise its borrowing limit.

The new speaker, elevated to the country’s third-highest constitutional post by a conservative rebellion, will face demands from those same rebels to extract concessions from a president who has little to lose by standing firm. At stake for conservatives will be the one clear victory they have scored since the Tea Party revolution of 2010: firm statutory limits on spending signed into law in 2011, which Mr. Obama has said he can no longer abide.

In turn, the Republican Party, already wrestling with the effect of Mr. Trump’s populist insurgency on its chances at the White House, could find itself with the political challenge of justifying to moderate voters yet another Washington crisis, prompted by an even more obstreperous, confrontational House majority.

“Having been hoisted to the speaker’s chair by what was essentially a revolt,” David Axelrod, a former senior adviser to Mr. Obama, predicted, the next speaker will not have the freedom to compromise with the president.

“This group is not installing him to pursue compromise and mutual cooperation,” Mr. Axelrod said.

Presidential aides have begun to take stock of a changed political landscape that could include some last-minute deal-making with Mr. Boehner before he heads back to Ohio. There could be a longer-term budget agreement that also deals with raising the nation’s debt ceiling, and possibly even a major infrastructure bill, long talked about and long stalled.

“John’s not going to leave for another 30 days, so hopefully he feels like getting as much stuff done as he possibly can,” Mr. Obama said during a news conference with the Chinese president on Friday.