Major Wall Street indices reversed early losses to rally as Apple Inc (>> Apple Inc.) and Boeing Co (>> Boeing Co) extended gains fueled by strong earnings reports earlier this week.

Buying picked up once the benchmark S&P 500 rebounded to hold above 2,000, a psychologically important level.

"There's so much uncertainly about where the market is going to be two weeks from now," said Michael James, managing director of equity trading at Wedbush Securities in Los Angeles, adding that traders fear a declining market but also don't want to miss out on potentially dramatic upswings.

The Dow Jones industrial average <.DJI> rose 164.34 points, or 0.96 percent, to 17,355.71. The S&P 500 <.SPX> gained 13.05 points, or 0.65 percent, to 2,015.21 and the Nasdaq Composite <.IXIC> added 29.52 points, or 0.64 percent, to 4,667.51.

Earlier, weak results hit European shares, with Royal Dutch Shell weighing on the market after it missed earnings expectations. The oil major, which closed down 4.3 percent, said it would cut spending by $15 billion over three years due to slumping crude prices.

German bond yields initially fell as worries over Greece's new anti-bailout government buoyed demand for top-rated assets, but the yield on U.S. Treasuries rose after surprisingly strong weekly data on American jobless claims bolstered optimism.

"You have two things going on in equity markets, and both are negative right now. Greece is to some degree being underestimated as a potential problem," said Dan Morris, global investment strategist at asset manager TIAA-CREF.

"At the same time, generally speaking, you haven't had great earnings numbers out of the U.S. Guidance is going down, earnings estimates are coming down," Morris said.

Morris calculated earnings growth for U.S. companies after stripping out Apple's blowout numbers this week is about 2 percent, which isn't very good. The overall growth rate is 7 percent, but a huge chunk of that is Apple, he said.

MSCI's all-country world stock index <.MIWD00000PUS>, a measure of stock performance in 45 countries, fell 0.19 percent. The FTSEurofirst 300 <.FTEU3> index of top European shares closed down 0.12 percent at 1,473.19 points.

The S&P 500 is trading just north of a critical technical support level at 1,991, with the release Friday of fourth-quarter U.S. gross domestic product a key indicator of the market's direction, said Paul Mendelsohn, chief investment strategist at Windham Financial Services in Charlotte, Vermont.

"We get a big number tomorrow, in terms of GDP. That's going to make or break where this market is going," Mendelsohn said.

A Reuters poll shows expectations of 3.0 percent growth in GDP.

Greece endured a fourth day of market jitters after Sunday's election with its newly installed government at loggerheads with international creditors as it begins to roll back austerity measures imposed in its bailout deal.

Yields on German 10-year bund , the euro zone benchmark, fell in early trade but closed slightly higher at 0.357 percent.

Yields on U.S. 10-year government bonds rose to 1.7597 percent, with the price falling 9/32.

The 10-year British gilt yield dropped below 1.4 percent for the first time, breaking a record that had held even during the depths of the euro zone debt crisis in July 2012.

Gilt yields fell on the U.S. Federal Reserve's promise to be patient before it raises interest rates and on uncertainty about Greece's new government.

U.S. crude futures settled higher after earlier turning negative on a report from oil services firm Genscape that showed further inventory builds in energy hub Cushing, Oklahoma.

U.S. crude rose 8 cents to settle at $44.53 a barrel.

Brent settled 66 cents higher at $49.13 a barrel.

Switzerland's franc again dominated trade on major currency markets, weakening against the euro and dollar amid renewed speculation of intervention by the Swiss National Bank, while commodity-based currencies fell against the greenback.

The franc sank to 1.0430 francs per euro in morning trade in Europe , by far its weakest since the SNB triggered the most violent move in a major currency in four decades by dumping its cap on the franc two weeks ago.

Against the dollar, the euro was last up 0.30 percent at $1.1316. The dollar rose against the Japanese yen 0.71 percent to 118.37.

(Reporting by Herbert Lash; Editing by Christian Plumb)

By Herbert Lash

Stocks treated in this article : Boeing Co, Apple Inc.