Surprisingly benign inflation data, solid retail sales, tumbling oil prices and strong earnings boosted stocks Thursday, with the Standard & Poor's 500 (search) index hitting a four-year high.

Both the Nasdaq and the S&P 500 rallied for the sixth day in a row.

The Dow Jones industrial average (search) rose 71.50 points, or 0.68 percent, to end at 10,628.89. The Standard & Poor's 500 Index (search) advanced 3.21 points, or 0.26 percent, to close at 1,226.50. The technology-laced Nasdaq Composite Index (search) gained 8.71 points, or 0.41 percent, to end at 2,152.82.

Shares of Apple Computer Inc. (AAPL) and Genzyme Corp. (GENZ), drove the Nasdaq higher, while General Motors Corp. (GM ) led the 30 stocks in the blue-chip Dow average.

"I was very pleasantly surprised by the releases today, with low inflation and very strong retail sales growth. And in general, second-quarter earnings are off to a very strong start," said Lincoln Anderson, chief investment officer at LPL Financial Services. "This is just unalloyed good news, and no dark spots in there that I can see."

Apple shares rose 6.3 percent, or $2.40, to $40.75 after the maker of Macintosh computers and iPod digital music players posted better-than-expected earnings a day earlier.

Also in the tech sector, Advanced Micro Devices Inc. (AMD) gained 3.3 percent, or 63 cents, to $19.88 on the New York Stock Exchange after the company posted an unexpected profit.

Genzyme reported a 58 percent jump in second-quarter profits, well ahead of expectations. Its shares rose 6.5 percent, or $3.965, to $65.30.

Shares of GM rose 3.2 percent, or $1.13, to $37 on the NYSE after investment bank and brokerage Lehman Brothers said GM may expect a gain of more than 50 percent in retail sales.

More than a week into the rally, analysts wondered how much longer stocks can keep their momentum.

"We got the earnings from Apple and now people are wondering, 'What's next?"' said Paul Nolte, director of investments at Hinsdale Associates, a boutique money management firm in Hinsdale, Illinois, with $50 million under management. "We've rallied six days now in a row and people are looking for the next bit of good news. We've gotten some pleasant surprises now from a variety of companies. We're going to need to see more of that."

Despite the advance, the major indexes pulled back from their session highs as investors collected profits from the past week's run-up in stock prices. The indexes have risen between 3 percent and 4 percent over the last six trading days.

Crude oil futures tumbled after the International Energy Agency (search ) predicted global demand would ease. A barrel of light crude settled at $57.80, down $2.21, on the New York Mercantile Exchange (search ).

Wall Street was encouraged by the latest reading of the Labor Department's Consumer Price Index (search), which measures how much consumers pay at the retail level. The CPI was unexpectedly flat for June, while "core" CPI — with food and fuel costs removed — edged just 0.1 percent higher.

"That reflects an economy that seems to have inflation under control while growth remains fluid," said Harry Michas, stock index futures trader at Man Financial's manmarketmonitor.com.

In a rare bit of good news for the airline sector, Southwest Airlines Inc. (LUV) had a 41 percent surge in profits for the second quarter. The company credited fare increases and rising passenger traffic for helping overcome rising fuel prices. Southwest climbed 44 cents to $14.42 and lifted other airline stocks as well. AMR Corp., parent of American Airlines, gained $1.08 to $13.87, while Delta Air Lines Inc. rose 61 cents to $4.05

The struggling automotive sector also got a boost, with General Motors Corp. jumping $1.13 to $37 after analysts at Lehman Brothers upped the stock to "equal weight" from "underweight." Ford Motor Co. (F) added 20 cents to $10.89 as well. Both stocks also benefited from strong auto sales reported in June.

The earnings news wasn't all good, though.

Yum Brands Inc. (YUM), parent of the Taco Bell and KFC fast food chains, dropped $1.86 to $49.85 despite reporting a rise in second-quarter profits that beat Wall Street expectations by 5 cents per share. The company warned that its future earnings would fall below analysts' projections.

U.S. hotel operator Marriott International Inc. (MAR) missed estimates. Its shares slid 3.6 percent, or $2.50, to $67.90.

Top U.S. mortgage lender Countrywide Financial Corp. (CFC) warned it may miss second-quarter forecasts. Its shares eased 0.2 percent, or 6 cents, to $38.53.

Trading was heavy, with 1.57 billion shares changing hands on the New York Stock Exchange, above the 1.46 billion daily average for last year. About 1.87 billion shares were traded on Nasdaq, above the 1.81 billion daily average last year.

The number of shares advancing in value exceeded the number declining by a ratio of 6 to 5 on the NYSE and by about 8 to 7 on Nasdaq.

The Russell 2000 index of smaller companies fell 4.63, or 0.69 percent, to 663.02.

Overseas, Japan's Nikkei stock average rose 0.9 percent. In Europe, Britain's FTSE 100 was up 0.26 percent, France's CAC-40 gained 0.63 percent for the session, and Germany's DAX index climbed 0.41 percent.

Reuters and the Associated Press contributed to this report.