The measure passed the Senate on a vote of 68-30, and President Obama said in a statement he looked forward to signing the bill into law. The House of Representatives has already approved the bill.
"This bill is not perfect, but it is a critical first step toward economic recovery and restored hope for millions of Americans who call Puerto Rico home," Obama said.
The legislation would create a federal oversight board, appointed by Washington, with power to restructure Puerto Rico's unmanageable debt load.
The bill provides for a stay, or halt, to any litigation brought against the Puerto Rican government and its debt issuing agencies that is retroactive to December. This provides breathing room for the board to start the process of restructuring and oversee a sustainable budget process.
On Friday, Puerto Rico faces a potential default on a chunk of its debt if it cannot make $1.9 billion worth of payments. Puerto Rico's Governor, Alejandro Garcia Padilla, has said the island will default some of the debt.
Supporters said intervention by Washington lawmakers was necessary to help the island's 3.5 million U.S. citizens avert a "descent into chaos," as U.S. Treasury Secretary Jack Lew on Tuesday.
Puerto Rico has been waiting for months for Congress to act as its economic crisis worsened. It has already defaulted on some of its debt. The Caribbean island territory is reeling from a 45 percent poverty rate, as well as a steady flow of migration to the U.S. mainland that shrinks its tax base and shuttering of essential services.
In addition, it is suffering from a Zika virus outbreak that is hurting its critical tourism industry.
But many Puerto Ricans are leery of the proposed oversight board, fearing it could usurp the island's government and place investors' concerns over local priorities.
Puerto Rico's benchmark 2035 General Obligation bond rose 1 full point in price ahead of the final vote, to trade at 66.75 points, pushing the yield down to 12.663 percent.
Passage came after leaders of both political parties warned that failure to approve the legislation could lead to a U.S. taxpayer-funded bailout.
"This is the best and possibly the only action we can take to help Puerto Rico," Senate Majority Leader Mitch McConnell, a Republican, said.
"Doing nothing now ... (is) the surest route to both a taxpayer funded bailout of Puerto Rico and a humanitarian crisis for its people," McConnell said.
Senate Democratic Leader Harry Reid said he shared the concerns of many Democrats with the "excessive powers and appointment structure" of the oversight board, and he was unhappy with some labor provisions.
But Reid said he was voting for passage because Puerto Rico needed the help by Friday. "Otherwise we ... turn them over to the hedge funds and they will sue them to death," he said.
The seven member board, appointed by President Obama from recommendations given by party leaders in both the House and Senate, is supposed to be in place by Sept. 1, 2016.
Neither political party was entirely happy with the fix.
Democrats bridled at a Republican provision that might lower the minimum wage for some young workers and weaken overtime pay rules while some Republicans were concerned the bill could amount to a bailout of the island, or set a precedent for states in fiscal trouble to seek a similar arrangement.
"They'll say if a territory can receive unprecedented authority from Congress, then why shouldn't a state?" asked Republican Senator Chuck Grassley of Iowa.
The legislation is geared toward U.S. territories. Puerto Rico is not covered by current U.S. bankruptcy law under Chapter 9.
Democratic Senator Robert Menendez of New Jersey, opposing the measure, argued that Friday was an arbitrary deadline for action that did not excuse a "flawed" bill.
A vote for the bill was "a vote to authorize an unelected, unchecked and all powerful control board to determine Puerto Rico's destiny for a generation or more," Menendez declared.
Some senators, including Vermont independent Bernie Sanders, criticized the estimated $370 million cost of the legislation over five years, complaining that Puerto Rico will get stuck with the tab while it is struggling to reduce its debt. Sanders blasted this as "colonialism at its worst."
The non-partisan Congressional Budget Office, which issued that estimate, said that about $350 million of the total "would primarily cover fees of legal and financial consultants hired to restructure Puerto Rico's debt."
Related news:
> U.S. Senate blocks Democrats' plan to deny firearms to those on 'watch lists' after Orlando shooting
> Obama calls on U.S. Senate to approve UNCLOS to support Asia pivot