The vote, which allows the Senate to begin debate on health care reform legislation, was a victory for Trump, who had spent weeks cajoling, strong-arming and warning Republicans to get on board with his effort to overhaul Obamacare.
In recent weeks, several measures have been proposed -- but ultimately collapsed, revealing fissures within the Republican Party on how to reach a goal they have had since the Affordable Care Act was passed in 2010.
But the path forward was no clearer, as the Senate soon after voted down a Republican plan to repeal and replace former president Barack Obama’s signature health care reform.
Nine Republicans joined Democrats in rejecting the amendment in the first of several votes expected to repeal Obamacare.
Despite the skepticism of some Republicans over how the effort to dismantle the Affordable Care Act might affect millions of Americans, Trump was thrilled that debate could go ahead.
"This was a big step," he said, calling Obamacare a "disaster for the American people."
McCain, who announced last week he is suffering from brain cancer, cast a critical vote for the measure, leaving senators evenly split and forcing Vice President Mike Pence to break the tie for a 51-50 final count on allowing debate.
All 48 Democrats and independents voted against, along with Republicans Susan Collins and Lisa Murkowski.
McCain received a standing ovation from his colleagues as he entered the chamber, having made the trip from his home state of Arizona, where he was convalescing.
While he called for greater bipartisan cooperation in Congress, McCain directly denounced the closed-door process that has marked the health care reform effort, saying it was wrong to try to force lawmakers to "swallow our doubts and force it past a unified opposition".
"I don’t think that’s going to work in the end, and probably shouldn’t," he said.
One Republican plan under consideration would dismantle Obamacare but delay actual implementation of the repeal to allow time for a viable replacement to be crafted. It is expected to fail.
The question then becomes what can get over the finish line. Lawmakers have begun speaking about a "skinny" repeal that would dismantle only parts of the Affordable Care Act, but it is not yet clear whether the plan will gain traction this week.
"We can do better than Obamacare," Senate Majority Leader Mitch McConnell said.
"Today’s vote to begin debate is the first step."
Trump has repeatedly grilled fellow Republicans for not following through on their -- and his -- campaign pledge to repeal and replace Obamacare.
On the Democratic side, senators urged cooperation -- and restraint.
"I can’t believe this process and the hard and calculated rhetoric we see," Democratic Senator Joe Manchin of West Virginia said on Tuesday.
"The Affordable Care Act is not a perfect piece of legislation. It needs repair. We both agree to that. Then we need to fix it."
Forecasts by the non-partisan Congressional Budget Office on various health reform bills have predicted that millions of Americans would lose health care if the measures become law.
In the case of a bill that repeals Obamacare and provides no replacement, 32 million more people would be uninsured by 2026 as compared to current law, CBO forecast.
Some Republicans have expressed concern with how the legislation would impact Medicaid, the health insurance program for the poor and the disabled.
The latest repeal-and-replace bill would roll back an expansion of Medicaid and slash its federal funding.
It would also end the mandate that most individuals have health insurance, and allow states to let insurance companies offer bare-bones plans not allowed under current law.
Democrats have blasted the secretive process, accusing Republican leaders of rushing a mammoth bill to the floor without sufficient discussion or debate.
Several outside health groups have criticized the various iterations of the repeal-and-replace effort.
One of the most emphatic rejections came from a group of some 7,000 Catholic nuns, who wrote Senate leaders on Monday to say the bill "would be the most harmful legislation for American families in our lifetimes."