Stocks closed sharply higher and the Nasdaq notched an eighth day of gains on Thursday as improved labor market and retail sales data added to optimism a day before the June jobs report.

The Nasdaq was up 8.3 percent for the eight days, which is its best eight-day run in two years.

Based on the latest available data, the Dow Jones industrial average <.DJI> rose 93.47 points, or 0.74 percent, to end unofficially at 12,719.49. The Standard & Poor's 500 Index <.SPX> was up 14.00 points, or 1.05 percent, to finish unofficially at 1,353.22. The Nasdaq Composite Index <.IXIC> was up 38.64 points, or 1.36 percent, to close unofficially at 2,872.66.

(Reporting by Caroline Valetkevitch; Editing by Jan Paschal)