Oil edged higher on Wednesday as OPEC said it was committed to eroding a global surplus of crude, but increasing shale production in the United States and still-high global stocks threatened to pull prices lower.
Brent crude futures were up 27 cents at $55.16 a barrel at 1106 GMT, while U.S. crude futures were up 20 cents at $52.61.
Crude fell in the previous two sessions, but it received a boost from comments on Wednesday by the secretary-general of the Organization of the Petroleum Exporting Countries that the group was committed to cutting inventories to the five-year average.
Analysts warned that prices could quickly turn negative.
"It seems that the optimism in the oil market we have seen since the last few days of March is running out of steam," wrote Tamas Varga, PVM Oil Associates analyst, noting concerns about the "ever-increasing rise" in U.S. shale output.
OPEC and other producers such as Russia agreed to cut output by almost 1.8 million barrels per day in the first half of 2017 to drain a supply overhang that has persisted for nearly three years.
The cuts and talk of a possible extension enabled a rally in major oil contracts of some 10 % between March 22 and April 12, Varga said.
Geopolitical concerns have also helped underpin oil.
This week, U.S. President Donald Trump ordered a review of whether the lifting of sanctions against Iran was in the United States' national interests. A lifting of certain sanctions against Iran in late 2015 under a nuclear deal allowed Tehran to more than double its crude exports over 2016.
But U.S. stockpiles—and shale production—have cast doubt on whether the production cuts were enough. Data from the American Petroleum Institute showed on Tuesday that although crude inventories fell by 840,000 barrels in the week to April 14, they remained near record highs.
Gasoline stocks also posted a counter-seasonal build of 1.4 million barrels. Gasoline margins have since come under downward pressure, which analysts warned could undermine crude prices as well.
Official U.S. oil data is due to be published on Wednesday by the Energy Information Administration (EIA).
"Unless the (EIA) data shows something drastically different, this report should cause a severe dent in the bullish case (for oil prices)," said Sukrit Vijayakar, director of energy consultancy Trifecta.