WASHINGTON — The Senate’s top five Republican leaders have cosponsored legislation to extend until 2017 the Obamacare insurance subsidies that may be struck down by the Supreme Court this summer.

The legislation, offered by Sen. Ron Johnson (R-WI), one of the most politically vulnerable Senate incumbents in 2016, would maintain the federal HealthCare.gov tax credits at stake in King v. Burwell through the end of August 2017.

The bill was unveiled this week with 29 other cosponsors, including Senate Majority Leader Mitch McConnell (R-KY) and his four top deputies, Sen. John Cornyn (R-TX), John Thune (R-SD), John Barrasso (R-WY) and Roy Blunt (R-MO). Another cosponsor is Sen. Roger Wicker (R-MS), the chairman of the conference’s electoral arm.

Such a move would seek to protect the GOP from political peril in the 2016 elections when Democrats would try to blame the party for stripping subsidies — and maybe insurance coverage — from millions of Americans in three dozen states. A defeat for the Obama administration in a King ruling would likely create havoc across insurance markets and pose a huge problem for Republicans, many of whom have been pushing the Supreme Court to nix the subsidies.

“This bill is a first step toward reversing the damage that Obamacare has inflicted on the American health care system,” Johnson said.

He recently explained the rationale for the legislation, warning that Democrats would swarm the GOP with attacks and horror stories about “individuals that have benefited from Obamacare” and lost their coverage.

Democrats would probably demand a fix to make the subsidies permanently available if they go down. But they would be hard-pressed to vote down a bill to temporarily extend them if Republicans were to bring it up.

The Johnson bill also contains sweeteners for conservatives which are non-starters for Democrats — it would repeal Obamacare’s individual mandate and employer mandate, and remove federal rules requiring that insurance plans cover a minimum package of “essential health benefits.” If those provisions are ultimately stripped, though, the legislation could have legs.

That said, if the Supreme Court upholds the subsidies, Obamacare would continue to be implemented as is. A decision is expected in June.

Also notable is the Republicans who are not among the bill’s cosponsors, including three presidential candidates — Sen. Ted Cruz (TX), Sen. Rand Paul (KY) and Sen. Marco Rubio (FL) — as well as other vulnerable senators facing reelection including Sen. Mark Kirk (IL), Sen. Kelly Ayotte (NH) and Sen. Pat Toomey (PA).

Update 2:50 P.M. EDT: Though he’s not currently listed as an official cosponsor, Kirk’s spokeswoman Danielle Varallo told TPM on Thursday afternoon that he has signed on to Johnson’s legislation.