U.S. stocks ended off session lows Thursday, the final trading day of the holiday-shortened week, as oil prices recovered from session lows and the U.S. dollar index gave back some gains. (Tweet This)
The Nasdaq composite closed 0.1 percent higher, as Amazon.com rallied 2.3 percent and the iShares Nasdaq Biotechnology ETF (IBB) reclaimed some of its earlier gains to close up nearly half a percent. Apple closed down 0.4 percent.
The Dow Jones industrial average also squeezed out a gain, up 13 points after dipping 103 points in the open. IBM and Caterpillar contributed the most to gains, while Goldman Sachs and UnitedHealth contributed the most to declines.
"Once again, it's a very strong underlying bid in the market that we've seen in the last six weeks," said Adam Sarhan, CEO of Sarhan Capital.
Read MoreCNBC analysis: Don't trust those GDP numbers
The major averages still ended a five-week win streak, falling about half a percent over four days that saw some of the lowest trade volume of the year so far. Markets are closed Friday for Good Friday.
In the past week, Fed officials' comments on the possibility of raising rates as soon as April supported a reversal in the U.S. dollar index that weighed on commodities.
"You've got a combination of a pivot in a long-term run in both the dollar and oil and that's going to pressure equities," said Art Hogan, chief market strategist at Wunderlich Securities.
The S&P 500 ended a touch lower, as financials lagged, while energy closed about half a percent higher and telecommunications rallied 1 percent to lead advancers.
U.S. crude oil futures came well off session lows to settle 0.8 percent lower at $39.46 a barrel. The weekly oil rig count, released Thursday due to the Good Friday holiday, showed a drop of 15 oil rigs.
The U.S. dollar index pared gains after touching its highest in more than a week, but turned in its first positive week in four with a rise of more than 1 percent. The euro held near $1.118 and the yen was at 112.81 yen against the greenback.
Gold futures for April delivery settled 0.2 percent lower at $1,221.60 an ounce, down 2.61 percent for the week, its worst since Nov. 6.
Treasury yields held higher, with the near 0.88 percent and the 10-year yield around 1.9 percent. The bond market closed early Thursday, at 2 p.m. ET.
"The real reason for the market coming down in the last couple of days is the Fed rhetoric," said Peter Cardillo, chief market economist at First Standard Financial.
"Certainly the comments out of Bullard and some of the others indicates we're getting closer to a rate hike," he said.
Ahead of the open, St. Louis Federal Reserve President James Bullard said the Fed's next interest rate hike "may not be far off," provided the economy evolves as expected. However, he told reporters in a Reuters article he was undecided on whether to push for a rate hike at the Fed's April meeting partly because of the limited amount of data expected before then.
Bullard is a voting member of the Federal Open Market Committee and in an interview Wednesday was the latest Fed official to suggest rates could rise as early as April.
Read MoreTraders look to data as Fed confuses
"I think it's adding to the volatility, especially with the results of the meeting more dovish than expected, countered by commentary more similar to what we expect," said Kate Warne, investment strategist at Edward Jones.
Last week, the U.S. central bank left rates unchanged and lowered its projections for the number of hikes this year.
The Dow transports ended nearly 0.4 percent lower, well off session lows but still 1.85 percent lower for the week to end nine straight weeks of gains. American Airlines was the greatest decliner for the day and week.
"I think right now we're in pullback mode. There's a lot of profit-taking, end-of-month and end-of-quarter," Sarhan said of the morning decline in stocks. He's watching to see if buyers come in to support the market, or if the selling continues.
Read More Market calm has eerie parallels to pre-swoon August
"What's most important in my eyes is people are looking forward to employment next week," said JJ Kinahan, chief strategist at TD Ameritrade.
"As long as we hold above 2,000 (in the S&P) there's no reason to panic," he said.
In economic news, weekly jobless claims came in at 265,000. February durable goods orders declined 2.8 percent.
Non-defense capital goods orders excluding aircraft, a closely watched proxy for business spending plans, decreased 1.8 percent after advancing by a downwardly revised 3.1 percent in January, Reuters said.
"The durable goods report was clearly disappointing," Warne said. "I don't think anybody was surprised."
The Markit flash U.S. services PMI was 51.0 in March, up from 49.7 in February.
Major U.S. Indexes
Overseas, European stocks closed about 1.5 percent lower or more.
In Asia, the major indexes closed lower with the Nikkei 225 down 0.6 percent and the Shanghai composite 1.6 percent lower.
U.S. stocks closed lower Wednesday with energy stocks leading declines as oil settled below $40 a barrel.
With Thursday's mixed close, the S&P 500 remained lower for the year so far, while the Dow held about half a percent higher for 2016. Both indexes are within 5 percent of their 52-week intraday highs.
Read More Early movers: ACN, WGO, YHOO, WFC, XOM, PVH, BWLD, KBH, RTN & more
The Dow Jones industrial average closed up 13.14 points, or 0.08 percent, at 17,515.73, with Caterpillar leading advancers and Nike the greatest decliner.
The Dow closed 0.49 percent lower for the week, with Goldman Sachs the worst performer and Pfizer leading outperformers.
The closed down 0.77 points, or 0.04 percent, at 2,035.94, with financials leading four sectors lower and telecommunications the top advancer.
The index lost 0.67 percent for the week, with energy the worst performer and health care the top.
The Nasdaq composite closed up 4.64 points, or 0.10 percent, at 4,773.50.
The Nasdaq declined 0.46 percent for the week. Apple declined 0.24 percent for the week, while IBB gained 1.65 percent.
The CBOE Volatility Index (VIX), widely considered the best gauge of fear in the market, closed at 14.7.
Advancers were a touch ahead of decliners on the New York Stock Exchange, with an exchange volume of 887 million and a composite volume of nearly 3.4 billion in the close.
High-frequency trading accounted for 49 percent of March's daily trading volume of about 8.05 billion shares, according to TABB Group. During the peak levels of high-frequency trading in 2009, about 61 percent of 9.8 billion of average daily shares traded were executed by high-frequency traders.
On tap this week:
Markets closed for Good Friday
8:30 a.m.: 4th quarter GDP (third estimate)
8:30 a.m.: Corporate profits
*Planner subject to change.
More From CNBC.com: