The Nasdaq composite and Standard & Poor's 500 indexes closed at five-year highs Wednesday after a positive report on the economy's service sector pushed stocks modestly higher. A jump in oil prices, however, minimized Wall Street's gains.

Click here to visit FOXBusiness.com's Investing page.

According to preliminary calculations, the Nasdaq gained 14.39, or 0.61 percent, to 2,359.75, its best close since Feb. 16, 2001, when it closed at 2,425.35.

The Dow Jones industrial average rose 35.70, or 0.32 percent, to 11,239.55.

The Institute for Supply Management's service index, an important barometer of that sector's activity, came in at 60.5 for the month, up from 60.1 in February and better than the 59 reading economists expected. The modest gains were enough to encourage Wall Street about that sector's growth, but did not appear to reignite the market's interest rate worries.

Yet trading remained tentative as the Energy Department's weekly inventory report showed lower stockpiles of gasoline and distillate fuels, which drove up crude oil futures. A barrel of light crude settled at $67.07, up 84 cents, on the New York Mercantile Exchange — a 20 percent year-over-year rise.

"The tick up in oil prices hurts, but history has shown that interest rates have a much bigger impact on the stock market than oil," said Jack Ablin, chief investment officer at Harris Private Bank. "And looking at the ISM services number, you're seeing the kind of gradual, lazy improvement in the economy that's not going to really get rates going."

The S&P added 5.63, or 0.43 percent, to 1,311.56, its best showing since May 21, 2001, when it finished at 1,312.83.

Bonds climbed higher, with the yield on the 10-year Treasury note falling to 4.85 percent from 4.87 percent late Tuesday. The dollar was mixed against other major currencies, while gold prices rose, but remained below $600 per ounce.

The market's activity — which had the major indexes seesawing through the early part of the session — could be attributed to investor unease ahead of Friday's job creation report from the Labor Department. The report is a key indicator of the overall economy's health, and Wall Street remained concerned that a very strong economy would prompt more interest rate hikes from the Federal Reserve.

With that uncertainty looming and stocks at or near five-year highs, investors were unlikely to push stocks substantially higher without at least some kind of retrenchment over the next few weeks, analysts said.

"Nobody likes to buy into a market that's making new highs. People like to be IN a market that's making new highs," said Chris Johnson, manager of quantitative analysis at Schaeffer's Investment Research in Cincinnati. "We're pretty much at a top right now, and people are going to want to see a good-sized correction at some point before jumping in again."

In corporate news, strong corn seed sales helped agricultural supplier Monsanto Co. post an 18 percent jump in quarterly profits. The company's earnings beat Wall Street forecasts by 8 cents per share, but Monsanto nonetheless dropped 47 cents to $85.41 as its second-quarter forecasts came in lower than expected.

Apple Computer Inc. (AAPL) surged $6.04, or 9.9 percent, to $67.21 as the company unveiled new software that would allow its Macintosh computers running on Intel Corp. chips to use Microsoft Corp.'s Windows XP, a move to broaden the Mac's appeal among PC users. Microsoft (MSFT) rose 10 cents to $27.74 on the news, while Intel gained 18 cents to $19.48.

Grocery store operator Great Atlantic & Pacific Tea Co. Inc., more commonly known as A&P, declared a $7.25 special dividend, worth a total of $300 million, payable April 25 to shareholders of record April 17. A&P nonetheless lost 22 cents to $34.91 after having risen substantially for most of the session.

Shares of broadcaster CBS Corp. added 16 cents to $24.97 after NBC "Today" host Katie Couric announced she would move to CBS to anchor its evening news and contribute to "60 Minutes." NBC parent General Electric Co. slid 28 cents to $34.42.

Advancing issues outnumbered decliners by nearly 5 to 3 on the New York Stock Exchange, where volume came to 1.62 billion shares, compared with 1.52 billion traded at the same point on Tuesday.

The Russell 2000 index of smaller companies rose 3.94, or 0.52 percent, to 766.26, an all-time high for the small-cap indicator.

Overseas, Japan's Nikkei stock average fell 0.28 percent. In Europe, Britain's FTSE 100 was up 0.66 percent, Germany's DAX index rose 0.26 percent, and France's CAC-40 climbed 0.29 percent.

Click here to visit FOXBusiness.com's Investing page.