The Dow surged nearly 218 points, its biggest gain of the year. The Nasdaq composite index also reached a milestone, closing above 3,000 for the first time since December 2000.
Stocks started Tuesday higher, and momentum built throughout the day.
The government reported before the market opened that retail sales in February increased the most since September. Shortly after 2 p.m., the Federal Reserve said it expected the unemployment rate to keep falling.
Then, at about 3 p.m., JPMorgan Chase said it was raising its dividend and launching a $15 billion stock buyback program, all with the blessing of the Fed.
The Fed was planning on waiting until Thursday to release the results of its annual "stress tests" on banks, which determine which are healthy enough to raise their dividends. After JPMorgan's announcement, the Fed released the results early.
The Fed's action was the latest sign that the U.S. financial system was getting healthier. JPMorgan led the Dow higher, shooting up 7 percent. Other big banks including Bank of America, Goldman Sachs and Wells Fargo also gained 6 percent.
"That's what really made the day," said Jeffrey Kleintop, chief market strategist at LPL Financial. Banks were easily the best-performing stocks in the market, gaining almost 4 percent as a group.
The Fed's test results had some negative outcomes, too. While JPMorgan Chase and 14 other financial institutions passed, four, including Citigroup, failed. Citigroup stock was down 4 percent in after-hours trading following the Fed announcement.
The Dow finished at 13,177.68, its highest close since Dec. 31, 2007. The close put the Dow within 1,000 points of its record, 14,164.53, set less than three months earlier. All 30 stocks in the Dow closed higher, the first time that has happened this year.
The Nasdaq composite index rose 56.22 points, or 1.9 percent, to 3,039.88.
On Dec. 11, 2000, the last time the Nasdaq closed above 3,000, it was in the middle of a horrifying slide — from a peak above 5,000 in March 2000 to just above 1,100 in October 2002.
At the beginning of 2000, the peak of the dot-com frenzy, investors valued stocks in the Nasdaq composite index at an astronomical 175 times their per-share earnings over the previous year.
Google was not yet a public company, and the iPod didn't exist. Apple pulled in $2.3 billion in quarterly revenue. Many Nasdaq companies were Internet startups with high stock prices but big losses.
And many of them failed, taking the Nasdaq down with them.
Jack Ablin, chief investment officer at Harris Private Bank, said the key difference between the Nasdaq then and now is that the technology companies that dominate the index only promised profits 12 years ago.
"The Nasdaq hasn't done much of anything for 12 years, but it's had a huge rally in earnings," Ablin said.
Today, the profits are real. Apple reported $46 billion in revenue in its latest quarter. The Nasdaq composite, which includes more than 2,500 companies, trades at about 24 times earnings, according to Birinyi Associates.
The Standard & Poor's 500 index closed up 24.87 points, or 1.8 percent, at 1,395.96, its highest level since June 5, 2008. The S&P has gained 11 percent since Jan. 1, more than what it posts in an average year. The S&P is a 12 percent rally from its record of 1,565.15.
Brian Gendreau, market strategist at Cetera Financial, said stocks could still go higher. Investors are paying roughly 14 times the past year's earnings for the S&P 500 index. The long-term average is closer to 15.
"Valuations are still very cheap," he said.
The dollar rose against the euro and hit an 11-month high against the Japanese yen after the Federal Reserve assessment. The euro fell to $1.3073 late Tuesday from $1.3150 late Monday. The dollar soared to 83.08 yen from 82.26 late Monday.
The retail sales report showed a gain of 1.1 percent last month. Some of it reflected higher gas prices, but Americans also spent more on cars, clothes and appliances. Department stores had their biggest gains in more than a year. The government also revised its estimates higher for December and January.
Retail stores reported a 6.7 percent increase in sales in February compared with the same month a year ago.
A reading of confidence among small business owners also rose in February for the sixth month in a row. The National Federation of Independent Business optimism index reached its highest level in a year, helped by an increase in expected sales.
The rally gained strength in the afternoon when the Federal Reserve said it saw signs of an improving economy and expected the unemployment rate to keep falling. The Fed also said strains in the global financial markets have eased.
The combination of strong retail sales and the Fed announcement dampened hopes that the Fed would buy more bonds to stimulate the economy, and traders dumped U.S. Treasury debt. The yield on the 10-year Treasury note climbed as high as 2.12 percent, its highest since October.
Among companies making big moves:— Great Wolf Resorts jumped 27 percent to $5.13. Apollo Global Management said it has agreed to buy the indoor water park operator for $5 a share.— Urban Outfitters dropped 5.3 percent, the worst drop in the S&P 500 index. The retailer reported earnings that fell below what analysts were expecting after it had to mark down prices on women's clothing at its Anthropologie and Urban Outfitters stores.— Carmike Cinemas soared 17 percent. The Georgia-based movie theater chain reported earnings and sales that far outpaced what Wall Street analysts had expected.