The S&P 500 snapped a five-day string of declines in a broad-based rally on Thursday, as Spain's plans for economic reform eased some worries about one of the euro zone's most troubled countries.

The benchmark S&P 500 rose 1 per cent, its biggest per centage gain since the Federal Reserve announced its plan for a third round of stimulus on Sept. 13.

Spain announced a detailed timetable for economic reforms for the fiscally troubled nation and a tough 2013 budget based mostly on spending cuts.

"Any information that gives some understanding about what's going to happen is good for the market. It's small news, but more certainty is good," said Giri Cherukuri, head trader at OakBrook Investments LLC in Lisle, Illinois.

The EU's Economic and Monetary Affairs Commissioner, Olli Rehn, said Spain's detailed timetable for economic reforms goes beyond what the European Commission has asked of Spain. Rehn said it is an ambitious step forward.

Gold stocks ranked among the day's bigger gainers in the wake of Spain's news; the PHLX gold/silver index jumped 3 per cent.

Adding to the rally was a last-minute push by investors to reposition portfolios ahead of the quarter's end, with the S&P 500 on track for a gain of 6.2 per cent in the third quarter. Friday will be the quarter's last trading day.

"What we've seen is broadly a consolidation, but also an attempt by fund managers to position properly for the rest of the year, to be in the best sectors," said Bruce Zaro, chief technical strategist at Delta Global Asset Management in Boston.

The Dow Jones industrial average shot up 72.46 points, or 0.54 per cent, to 13,485.97 at the close. The Standard & Poor's 500 Index rose 13.83 points, or 0.96 per cent, to finish at 1,447.15. The Nasdaq Composite Index gained 42.90 points, or 1.39 per cent, to close at 3,136.60.

While the Nasdaq led Thursday's gains, it also led the market's declines earlier this week - its volatility possibly reflecting investors' nervousness about the US economic outlook, analysts said.

Apple, up 2.4 per cent at $US681.32, gave the biggest lift to the Nasdaq. The semiconductor index gained 2.3 per cent, bolstering the Nasdaq 100. Intel Corp was up 1.9 per cent at $US23.09.

After the bell, US-listed shares of Research In Motion surged 15 per cent to $US8.21 after the Canadian maker of the BlackBerry reported a smaller-than-expected quarterly loss. In the regular session, the stock closed at $US7.14 - up 2 per cent.

On the deal-making front, Tempur-Pedic International Inc agreed to buy rival mattress maker Sealy Corp for about $US242 million and assume about $US750 million in debt. Tempur-Pedic shares jumped 14.4 per cent to $US30.64, while Sealy's stock rose 2.3 per cent to $US2.19.

In the earnings realm, Discover Financial Services reported third-quarter earnings that beat expectations - and its shares climbed 7.3 per cent to $US39.71.

Stocks were rising before Spain's announcement on hopes that China would take steps to spur its slowing economy.

China has severely underestimated this year's global economic slowdown, and further cuts to Chinese interest rates or bank reserve requirements will hinge on any new deterioration in the external environment, a central bank adviser said on Thursday.

US economic data was mixed. A report showed initial jobless claims dropped by 23,000 to 359,000, sharply exceeding the decline of 4,000 that had been expected.

But the final read on second-quarter gross domestic product showed growth of just 1.3 per cent, weaker than an expected 1.7 per cent. And August durable goods orders tumbled 13.2 per cent, much more than the expected drop of 5 per cent.

Volume was below average at roughly 5.74 billion shares traded on the New York Stock Exchange, the Nasdaq and the Amex, compared with the year-to-date average daily closing volume of 6.53 billion.

Advancers outnumbered decliners on the NYSE by a ratio of slightly more than 3 to 1,and on the Nasdaq, about three stocks rose for every one that fell.

Reuters