Traders were reluctant to bet heavily a day before the Friday release of the November employment report. Just 5.62 billion shares changed hands on U.S. exchanges, shy of the 6.48 billion daily average this year.
Investors are also keeping watch on the "fiscal cliff" negotiations in Washington to see if lawmakers can reach a deal to avoid a series of spending cuts and tax hikes beginning in January.
"Right now we're just drifting, waiting to learn about the cliff and jobs," said Donald Selkin, chief market strategist at National Securities in New York. "The only stabilizing factor is that Apple is higher again, which is lending some support to the broader market."
Apple climbed 1.6 percent to $547.24, reversing losses incurred at the open. The stock was coming off its biggest one-day drop in four years on Wednesday, which occurred on concerns about higher capital gains taxes in 2013 and the company's tablet computer market share.
The S&P technology index was the best performing of the S&P 500's 10 major sectors, gaining 0.8 percent. Semiconductor stocks rallied a day after Broadcom forecast fourth-quarter revenue at the high end of its target range. Broadcom's stock rose 3.2 percent to $33.36 while the PHLX semiconductor index rose 1.1 percent.
The Dow Jones industrial average rose 39.55 points, or 0.30 percent, to 13,074.04 at the close. The Standard & Poor's 500 Index added 4.66 points, or 0.33 percent, to 1,413.94. The Nasdaq Composite Index gained 15.57 points, or 0.52 percent, to close at 2,989.27.
Monthly payroll numbers, which will be released by the Labor Department before the market opens on Friday, are expected to show a sharp slowdown in jobs growth, though that is largely due to the impact of Superstorm Sandy, which devastated the U.S. Northeast in late October and early November. The unemployment rate is seen holding steady at 7.9 percent.
Broader moves were limited, however, as traders focused on the "fiscal cliff" debate. About three weeks remain before higher tax rates would go into effect, which economists worry would dampen economic growth. Legislators are trying to come up with a deal to avoid some of the negative effects on the economy while still reducing the U.S. budget deficit.
While Republican leaders in the U.S. House of Representatives insist that raising tax rates on the rich is not negotiable, some GOP lawmakers now see it as inevitable to avoid the fiscal cliff.
Without action from Congress, tax cuts on capital gains and dividends will expire at the end of 2012. This has given investors a reason to sell certain stocks such as Apple that have done extremely well in recent years.
The CBOE Volatility Index, known as the VIX, rose 0.7 percent, "a reflection of the anxiety people have about the jobs report and skepticism over the cliff," Selkin said.
An S&P index of consumer discretionary shares gained 0.6 percent, lifted by Starbucks Corp shares' advance of 5.7 percent to $53.70 after Baird upgraded the stock to "outperform."
H&R Block climbed 5.1 percent to $18.26 after the company reported a quarterly loss that was narrower than expected.
Sirius XM Radio shares rose 0.7 percent to $2.79 after its board approved a $2 billion stock repurchase and declared a special dividend that gave a big payout to its largest shareholder, Liberty Media. Shares of Liberty climbed 2.7 percent to $109.24.
Garmin shares jumped 5.7 percent to $41.99 after Standard & Poor's said it would add the navigation device maker to the S&P 500 index. Garmin will replace R.R. Donnelley & Sons after the close of trading on Dec. 11.
Slightly more than 50 percent of the stocks traded on the New York Stock Exchange closed higher, while the number of advancing and declining stocks was about even on the Nasdaq.