Just two hours before the scheduled vote, Senate Majority Leader Mitch McConnell released a pared-down version of a new healthcare bill that would have left 15 million more people uninsured by next year, according to the nonpartisan Congressional Budget Office. Unable to pass even a so-called "skinny repeal," it was unclear if Senate Republicans could advance any health bill despite seven years of promises to repeal Obamacare.
A key vote to defeat the measure was cast by Sen. John McCain, who returned to the Senate this week after being diagnosed with brain cancer. In an impassioned speech the day he returned, McCain had called for bipartisanship on major issues of national concern, and a return to the "regular order" of legislating by committee.
Three Republicans joined with all Democrats to reject the amendment, which would have repealed a mandate that most individuals get health insurance and suspended a requirement that large companies provide coverage to their employees. It would have also delayed a tax on medical devices and denied funding to Planned Parenthood for a year.
The amendment was a last resort for Senate Republicans to pass something — anything — to trigger negotiations with the House.
"This is clearly a disappointing moment," said Senate Majority Leader McConnell. He put the healthcare bill on hold.
"It's time to turn the page," said Senate Minority Leader Charles Schumer of New York. "We are not celebrating. We are relieved."
McConnell had called his measure the Health Care Freedom Act. It was not intended to become law, but to open a path for a House-Senate conference committee to try to work out comprehensive legislation Congress could pass and send to Trump.
The measure would have repealed the unpopular Affordable Care Act provision requiring most people to have health insurance or risk a fine from the IRS. A similar requirement on larger employers would be suspended for eight years.
Additionally it would have denied funding to Planned Parenthood for a year, and suspended for three years a tax on medical device manufacturers. States could seek waivers from consumer protections in the Obama-era law, and individuals could increase the amount they contribute to tax-sheltered health savings accounts for medical expenses.
Ryan seemingly opened a path for McConnell earlier Thursday evening by signaling a willingness to negotiate a more comprehensive bill with the Senate. Some Republican senators had been concerned that the House would simply pass the "skinny bill," call it a day, and move on to other issues like tax reform after frittering away the first six months of Trump's presidency on unsuccessful efforts over healthcare. That move would have sent a shock wave through health insurance markets, spiking premiums.
Ryan sent senators a statement saying that if "moving forward" requires talks with the Senate, the House would be "willing" to do so. But shortly afterward, his words received varied responses from three GOP senators who'd insisted on a clear commitment from Ryan. It was not immediately clear whether the manoeuvre would succeed.
"Not sufficient," said McCain, who returned to the Capitol Tuesday to provide a pivotal vote that allowed the Senate to begin debating the healthcare bill, a paramount priority for Trump and the GOP.
Sen. Lindsey Graham initially said "not yet" when asked if he was ready to vote for the scaled-back Senate bill. But later, he told reporters that Ryan had assured him and others in a phone conversation that the House would hold talks with the Senate.
"I feel comfortable personally. I know Paul; he's a man of his word," said Graham.
"Let's see how everything turns out here, guys," Sen. Ron Johnson told reporters.
In the end, the 49-51 vote meant the end of the bill and the misgivings of a few Republican senators derailed the GOP's seven-year quest to roll back Obamacare. It remains to be seen whether a bipartisan deal can now be reached to stabilise insurance markets that have been rattled by rising premiums and insurer exits.
Numerous polls had shown little public support for the GOP's earlier proposals to repeal and replace Obama's law. A recent AP-NORC poll found only 22% of the public backing the Republican approach, while 51% were opposed.
The dizzying series of legislative manoeuvres this week left even veteran senators puzzled.
"We're in the twilight zone of legislating," said Democratic Sen. Claire McCaskill of Missouri.
This story has been updated.