NEW YORK - Stocks advanced Friday, capping a strong week, helped by a recovery in the price of oil and earnings from Olive Garden owner Darden Restaurants and sportswear giant Nike.

The Nasdaq composite index inched closer to its all-time high, set at the top of the dot-com bubble.

The Dow Jones industrial average rose 168.62 points, or 0.94 percent, to 18,127.65. The Standard & Poor's 500 index rose 18.83 points, or 0.9 percent, to 2,108.10, and the Nasdaq added 34.04 points, or 0.68 percent, to 5,026.42.

The Nasdaq closed 22 points from the record high of 5,048 it set in March 2000. It has taken the Nasdaq 15 years to recover from the dot-com bubble, while the S&P 500 and the Dow recovered from their losses in 2007 and 2006, respectively.

Dow member Nike was among the biggest gainers Friday, rising $3.66, or 3.7 percent, to $101.98. Nike's results beat expectations, but investors focused more on the fact that foreign sales remain strong despite the rising dollar.

The rapid rise in the dollar has been a sore spot for investors. The dollar is up more than 8 percent against the major currencies, which makes goods made in the United States more expensive abroad and has had a direct negative impact on sales. The dollar rose to 120.09 yen from 120.76 Thursday. The euro rose to $1.0809 from $1.0668 the previous day.

In oil markets, after dropping more than 3 percent Thursday, U.S. benchmark oil for April delivery jumped $1.76, or 4 percent, to $45.72 a barrel. Energy stocks rose far more than the rest of the market. The S&P 500's energy sector gained 2 percent. Brent crude, the international standard, rose 89 cents, or 1.6 percent, to $55.32 a barrel.

In other futures trading on the NYMEX, natural gas fell 2.7 cents to close at $2.786 per 1,000 cubic feet.

In the metals markets, precious and industrial metals futures rose. Gold gained $15.60 to $1,184.60 an ounce, silver jumped 77 cents to $16.88 an ounce, and copper rose 10 cents to $2.76 a pound.