Crude futures settled down on Thursday, pressured by a rally in the dollar which countered bullish sentiment from a drawdown in U.S. stockpiles that was much steeper than expected.
Position squaring ahead of the expiry of the front-month contracts in gasoline and diesel also diverted some investor attention from crude, brokers said.
Oil has slid more than $10 a barrel over the past month. Global benchmark Brent neared a six-month trough earlier this week and U.S. futures neared four-month lows, pressured by a global glut, a resurgent dollar and China's tumbling stock market.
Oil prices got support on Wednesday after U.S. government data showed an unexpectedly large weekly draw of more than 4 million barrels of crude, or at least 20 times what analysts expected.
The market rose the positive wave from the data higher again early on Thursday, advancing by up to 1% before gains unraveled in afternoon trade.
Brent settled down 7 cents, or 0.1%, at $53.31 a barrel.
U.S. crude closed lower by 27 cents, or 0.6%, at $48.52.
"You have a stronger dollar to deal with," David Thompson, executive vice president at Powerhouse, an energy-specialized commodities broker in Washington, said, explaining the market's reversal.
A robust dollar often weighs on commodities as raw materials like oil, traded in the U.S. currency, become less affordable for users of the euro.
The front-month contracts in gasoline and diesel, set to expire on Friday, dominated activity on the petroleum complex.
Gasoline settled up 0.3% after rallying 1.2% earlier on the strength of Wednesday's U.S. government data showing demand for the fuel rose over 6% from a year ago. Ultra low sulfur diesel settled flat, also after rising about 1%.
"With the products expiration tomorrow, the cash markets around the Gulf Coast and New York Harbor are well supplied," causing gasoline and diesel to come off their highs, said Donald Morton, trader at Connecticut-based Herbert J. Sims & Co.
Oil prices have lost more than half their value over the past year as major producers pumped at near-record levels despite a global glut. The Organization of the Petroleum Exporting Countries produced around 3 million barrels per day above demand in the second quarter, data shows.
Dutch Bank ABN AMRO said Thursday Brent could average $65 in 2016, versus its previous forecast of $75.
(Additional reporting by Christopher Johnson in London and Keith Wallis in Singapore; Editing by Meredith Mazzilli and David Gregorio)