House Speaker John Boehner told the Republican caucus Friday morning that he will vacate his position as leader of the House of Representatives and leave his Ohio congressional seat by the end of October, The New York Times and various outlets reported.

Boehner clashed frequently in recent years with the far-right members of his caucus, who viewed Boehner as weak and unwilling to stand up for conservative principles even if it meant creating chaos. He presided over one government shutdown and multiple 11th-hour face-offs over the debt ceiling, but this view nevertheless persisted among the most conservative members.

Most immediately, Boehner has been under intense pressure to include a measure defunding Planned Parenthood in a government funding bill that must pass by October 1. The fury was driven, at least ostensibly, by outrage over heavily edited and misleading videos about Planned Parenthood that have gained wide circulation on conservative media in recent months.

If Congress did pass such a measure, Obama would definitely veto it, creating another yet another government shutdown. Republican leaders, including Boehner, are widely understood to oppose creating a government shutdown one year before a presidential election, particularly over an issue like women’s health, where Republicans are already vulnerable. (The public favors federal funding of Planned Parenthood.)

There have been serious rumblings among conservatives about stripping Boehner of his post were he to back down. By announcing his resignation, Boehner is likely calculating that he can take the air out of that threat and fall on his sword one last time to keep the government open—something that might have lead to his involuntary ouster from the speakership anyhow. Boehner reportedly told Republican members he was resigning “for the good of the party.”

But this road is still fraught with peril. Boehner reportedly wants House majority leader Kevin McCarthy to take over the Speaker slot, but McCarthy will face the same skepticism from conservatives, particularly if he supports a clean government funding resolution. The far-right members might yet push for one of their own to become Speaker.

And Senate majority leader Mitch McConnell is pushing only a three-month funding resolution with no Planned Parenthood language, meaning this whole fight would happen again in December—with conservative members perhaps already emboldened by having thoroughly defeated Boehner.