Stocks extended gains on Tuesday, as the Nasdaq rose more than 2 percent, amid optimism about the upcoming earnings season and hopes for a global economic recovery.

Shares of Apple Inc advanced nearly 2 percent at $189.56, leading gains on the Nasdaq for a second day.

The Dow Jones industrial average <.DJI> increased 166.41 points, or 1.73 percent, at 9,766.16. The Standard & Poor's 500 Index <.SPX> was up 19.13 points, or 1.84 percent, at 1,059.59. The Nasdaq Composite Index <.IXIC> rose 41.25 points, or 1.99 percent, at 2,109.40.

(Editing by Jeffrey Benkoe)