US stocks closed slightly higher Friday after upbeat consumer confidence data shaved an edge off fears about the nation's looming "fiscal cliff."
After opening mostly lower, the stock indices crossed into positive territory after a November survey showed consumer confidence rose more than expected and hit the highest level since July 2007.
"That's good news for consumer spending and economic growth," said Jennifer Lee at BMO Capital Markets.
But market sentiment, battered after two days of heavy losses, was fragile and the Dow Jones Industrial Average closed up a mere 4.07 points (0.03 percent) at 12,815.39.
The S&P 500-stock index gained 2.34 (0.17 percent) at 1,379.85, while the tech-rich Nasdaq Composite rose 9.29 (0.32 percent) to 2,904.87.
"The uncertainty surrounding the 'fiscal cliff' is giving most investors pause right now," said Jim Cunningham at Schaeffer's Investment Research.
"We had a see-saw battle throughout the day, and in the end, neither bulls nor bears really took control."
Stocks barely rebounded from a two-day losing streak that had left the Dow industrials 3.3 percent lower.
Boeing led the Dow higher, soaring 3.2 percent, and Caterpillar gained 1.5 percent.
Dow member Disney was the blue-chip laggard. The media and entertainment giant plunged nearly six percent after reporting fiscal fourth-quarter sales that missed estimates.
Heavyweight Apple, the most valuable US company, helped lift the Nasdaq with a 1.7 percent gain.
Travel website Kayak surged 27.8 percent after agreeing to be bought by rival Priceline (-0.3 percent) in a stock-and-cash deal worth $1.8 billion.
Groupon shares plunged to their lowest level since the online deals giant went public a year ago, as analysts offered a harsh response to a disappointing earnings report.
Groupon tumbled 29.3 percent to close at $2.77 -- down some 85 percent from the $20 public offering price one year ago.
Bond prices rose. The 10-year US Treasury yield fell to 1.61 percent from 1.63 percent late Thursday, and the 30-year dropped to 2.75 percent from 2.77 percent. Bond prices and yields move inversely.