NEW YORK — Wall Street extended a huge rally Friday as investors stormed back into the market, relieved that the government plans to restore calm to the financial system by rescuing banks from billions of dollars in bad debt. The Dow Jones industrials rose about 300 points, giving them a massive gain of more than 700 over two days, and Treasurys fell as money flowed into equities.

A new government ban on short selling, or placing bets that a stock will fall, likely added to the market's gains.

"A big chunk of this is scaring all the shorts to cover their bets," said Joe Battipaglia, market strategist at Stifel, Nicolaus & Co.

Treasury Secretary Henry Paulson, speaking about the rescue plan, said a bold approach is needed to remove troubled assets from the books of financial firms. He offered few details, but said he would work on the plan through the weekend with congressional leaders.

A plan to help financial companies excise bad mortgage debt from their ledgers likely would alleviate much of Wall Street's uncertainty about credit worthiness that has been sending the markets into tumult over the past week. Lending grinded to a virtual standstill in the wake of this week's bankruptcy of Lehman Brothers Holdings Inc. and the bailout of teetering insurer American International Group Inc.

The government took other steps Friday to restore stability to the financial system. The Federal Reserve said it will expand its emergency lending and let commercial banks finance purchases of asset-backed paper from money market funds. The Fed injected another $20 billion in temporary reserves into the U.S. financial system. The central bank also will buy short-term debt obligations issued by Fannie Mae, Freddie Mac and the Federal Home Loan Banks.

And to help calm investors' anxieties, the Treasury Department has decided to use a Depression-era fund to provide guarantees for U.S. money market mutual funds. Money market mutual funds are typically considered safe, but many investors have been fleeing them due to worries about the funds' exposure to souring corporate debt.

To help limit the freefall in financial stocks, the Securities and Exchange Commission on Friday enacted a temporary ban on the short-selling of nearly 800 financial stocks. Short-selling is the common practice of betting against a stock by borrowing shares and then selling them in the open market. A short-seller's hope is the stock will fall; if it does, the stock can be bought back at the lower price. Those cheaper shares can be returned to the lender, allowing the investor to pocket the profits. Traders can lose, however, if the stock rises.

Wall Street observers have disagreed over the extent to which pressure from all those bets that a stock will fall shaped investor sentiment and strangled some financial stocks, like those of Lehman Brothers last week. Some say the fundamental problems with the financial stocks warranted the pessimism while others say the short selling was a death knell for some financial names.

"The federal government has been petitioned by Wall Street to take evasive action in the money markets, the stock and bond markets, to avoid a complete meltdown of the credit system," said Battipaglia. "Once the credit system melts down, the economy falls. We can hand-ring about if this is the proper thing for the government to do, or if Wall Street pulled the panic button too soon, but that's something for the historians to sort out."

It's difficult to quantify how much of the market's gains reflect short sellers who are forced to step in and cover their bets by buying now rising stocks that had predicted would fall. While that played some role in the advances Thursday and Friday, the Nasdaq composite index — dominated by big technology stocks, not financials — showed big gains along with the Dow and the Standard & Poor's 500 index.

In late afternoon trading, the Dow rose 296.29, or 2.69 percent, to 11,315.96 after having been up as much as 463.36; Friday was a quarterly "quadruple witching" day, which marks the simultaneous expiration of options contracts, an event that often adds to volatility and heavy volume leading to swings in the major indexes.

Even with Friday's big gains, stocks are essentially flat for the week after whipsaw sessions. Wall Street saw a massive loss Monday, a rebound on Tuesday, another drop Wednesday, and the rally on Thursday. The Dow has logged moves of more than 400 points every day except Tuesday.

Broader stock indicators also surged. The S&P 500 index rose 43.71, or 3.62 percent, to 1,250.22, and the Nasdaq composite index rose 55.06, or 2.50 percent, to 2,254.16.

Treasury prices dropped as investors poured money back into stocks. The yield on the 3-month Treasury bill — a safe investment to which investors have rushed this week — rose to 0.95 percent from 0.07 percent late Thursday. Yields move opposite from price. The yield on the benchmark 10-year Treasury note shot up to 3.76 percent from 3.53 percent late Thursday.

"Everything they had done had been a Band-Aid approach, at the margins," said Jay Mueller, economist at Strong Capital Management. "Now we're dealing with the root problem."

The stock market's enormous moves for the week reveal how jittery investors have been about the tightness in the credit markets the possibility that other financial companies might succumb to the difficulties in the markets. Moves Thursday by the Fed and other major central banks to inject billion into global money markets perhaps helped forestall steeper selloffs but didn't diffuse the Sturm und Drang and overall loss of confidence hammering the markets.

The only lasting move in a week of intense volatility came late in Thursday's session when reports emerged that the government was considering a massive bailout. Wobbly stocks rocketed higher, giving the Dow a 402-point gain Thursday that continued into Friday.

"If a solid plan is put in place, it's definitely going to be a positive in easing the pain," said Stephen Carl, principal and head of equity trading at The Williams Capital Group. He added, though, that "it depends on how it's structured."

The dollar rose against most other major currencies in Friday trading. Gold prices fell. Light, sweet crude rose $6.01 to $103.89 a barrel on the New York Mercantile Exchange.

While stocks rose broadly, the financial sector was one of the strongest gainers as investors expressed their relief over the prospect of a government rescue. The two remaining independent investment banks logged big gains as fears dissipated that they would be felled by the same tight cash shortages that squeezed Bear Stearns Cos., Lehman Brothers, AIG and others.

Goldman Sachs Group Inc., jumped $19.09, or 18 percent, to $127.09, while Morgan Stanley jumped $4.45, or 20 percent, to $27.

Advancing issues outnumbered decliners by about 7 to 1 on the New York Stock Exchange, where volume came to a heavy 2.1 billion shares.

The Russell 2000 index of smaller companies rose 20.07, or 2.77 percent, to 743.75.

Overseas stock markets soared. Japan's Nikkei stock average jumped 3.8 percent, and Hong Kong's Hang Seng index surged 9.61 percent. In Europe, Britain's FTSE 100 jumped 8.84 percent, Germany's DAX index advanced 5.56 percent, and France's CAC-40 rose 9.27 percent.