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.