(CNN) -- The U.S. House of Representatives has passed the revised version of $700 billion bank bailout plan intended to bolster the ailing U.S. financial system.
Wall Street traders had been watching developments in Washington closely.
The House rejected the original bill on Monday, sending stocks tumbling around the world.
But lawmakers approved the rescue package, backed by U.S. President George W. Bush and Treasury chiefs, Friday after the U.S. Senate passed it by a large majority on Wednesday.
Congress voted 263 to 171 in favor of the bailout bill.
President Bush signed the bill into law Friday afternoon.
Stocks on Wall Street slumped Friday, as the brutal week ended. The Dow Jones industrial average lost 1.5 percent, according to early tallies. For the week, the Dow ended down 818 points, the biggest weekly point loss in seven years and the third-biggest weekly loss on a point basis ever.
The Standard & Poor's 500 index lost 1.4 percent Friday and the Nasdaq composite lost 1.5 percent.
Bush thanked all those involved and said the bill was essential to stopping the crisis on Wall Street becoming a crisis in the wider economy.
Bush said it sent a message to the rest of the world that the U.S. was ready to take action to ease the credit crunch.
He said it would take sometime for the bill to have an impact on the American economy.
Federal Reserve chairman Ben Bernanke said he applauded the vote.
"It demonstrates the government's commitment to do what it takes to support and strengthen our economy. The legislation is a critical step toward stabilizing our financial markets and ensuring an uninterrupted flow of credit to households and businesses.
"The Federal Reserve will continue to work closely with the Treasury as it undertakes these new initiatives. We will continue to use all of the powers at our disposal to mitigate credit market disruptions and to foster a strong, vibrant economy," Bernanke said.
Treasury Secretary Hank Paulson, the author of the plan, said Americans would appreciate the leadership of their elected representatives.
"We will move rapidly to implement the new authorities, but we will also move methodically," he said.
Democrat House Speaker Nancy Pelosi said after the vote that hearings would be held into how the U.S. economy end up needing the bailout.
Pelosi said the U.S. needed regulatory reform to prevent the same situation being repeated in the future.
She said a much better bill may have been achievable in different circumstances, but the situation was urgent and middle class needed to be protected.
Stock markets around the world have endured days of turmoil as a consequence of uncertainty over Washington's response to the credit crisis.
U.S. markets opened brightly Friday, following heavy losses the previous day, amid fresh expectation that the bailout plan would go through. By 11.50 a.m. (1550 GMT) the Dow Jones was up 1.79 percent and the Nasdaq was up 2.80 percent.
Asian markets slipped earlier in the day with Japan's Nikkei Exchange closing the week down 215.05 points, or about 1.9 percent at 10,939.71 -- a new three-year low. Hong Kong's Hang Seng dropped 2.9 percent to 17,682.40 and key indexes across the region were all down.
European markets were flat in morning trading, but rallied after Wall Street opened with London's FTSE 100 up 2.15 percent, Paris' CAC up 2.96 percent and Frankfurt's DAX up 2.55 percent.
The banking world has been in turmoil in recent weeks with many institutions scrambling for survival as credit has dried up, leaving many holding "toxic" subprime debt following the collapse in U.S. house prices.
In the latest development Friday, troubled U.S. bank Wachovia announced it would merge with Californian banking giant Wells Fargo in a deal valued at approximately $15.1 billion. (Full story)
The merger will include all of Wachovia's banking operations, Well Fargo said. Wachovia had looked set to be sold to Citigroup in a deal brokered by the federal government.
The core of the Senate financial bailout bill is a plan to buy troubled assets from banks, but the proposal includes a number of new provisions aimed at ordinary people struggling under the credit crunch. Blog: Will the bailout plan fix the economy?
The changes -- including $110 billion in tax breaks and raising the limit at which bank deposits are guaranteed from $100,000 to $250,000 -- were intended to attract more votes from the House -- especially from Republicans, two-thirds of whom voted against that version. Explainer: What next for the bailout plan?
But the bill also includes some odd sweeteners -- so-called "pork-barrel legislation" -- such as an excise tax exemption for a very specific type of arrow used by child archers, a $478 million tax incentive scheme to encourage movie companies to continue producing films in the U.S, and measures to allow employers to provide benefits to employees who commute to work by bike. Watch where's the pork? »
Speaking in Friday's debate, Republican Congressman Steven LaTourette accused senators of "larding up" the bill. "Let's do it right. The pork doesn't belong in the bill," he said.
Copyright 2008 CNN. All rights reserved.This material may not be published, broadcast, rewritten, or redistributed. Associated Press contributed to this report.