U.S. crude oil futures regained their footing, and rose above $137, but were still below session highs midday Wednesday despite a larger-than-expected drawdown in weekly government inventory data.
Heating oil futures extended gains, pulling up the complex, even though distillate stocks, in which heating oil is a major part, rose for the ninth consecutive week.
"The concerns over global distillate supplies remain, despite the recent trend of building inventories in the U.S.," said John Kilduff, senior vice president at MF Global in New York. "Until we see demand really crack, I would look for heating oil to remain the counter-seasonal leader." he said.
In the early going, rising tensions in the Middle East weighed on the dollar and that helped lift crude futures.
In the previous two sessions, crude futures had fallen $9.25 or 6.4 percent following a record run to $145.85 before the July Fourth holiday weekend.
On the New York Mercantile Exchange, U.S. light, sweet crude settled at $136.05 a barrel, after trading from $135.34 to $138.28.
"The draw in crude supply (was) initially interpreted as supportive. However, virtually all of the crude draw was in the nonrepresentative West Coast region," said Jim Ritterbusch, president of Ritterbusch & Associates in Galena, Illinois.
London Brent crude was also higher.
The U.S. Energy Information Administration said that for the week to July 4, domestic crude stocks fell 5.9 million barrels to 293.9 million barrels, the lowest since the week to Jan. 25 when stocks stood at 293 million barrels. Crude stocks in the West Coast region fell 4.8 million barrels to 53.6 million barrels.
Supplies also fell in the Gulf Coast and at the Cushing, Oklahoma, delivery point for NYMEX traded oil and a part of the Midwest region, where supplies in total were unchanged.
Supplies rose in the East Coast. Analysts in a Reuters poll had expected on average a drawdown of 1.8 million barrels.
Crude oil imports were down sharply, by 621,000 barrels per day to 9.5 million bpd, while refinery utilization was unchanged at 89.2 percent of capacity.
Gasoline stocks rose 900,000 barrels to 211.8 million barrels, against the forecast for a 200,000 barrel drawdown. Gasoline demand fell by 10,000 bpd to 9.35 million bpd.
Distillate supplies, which include heating fuel and diesel, were up for the ninth week in a row, by 1.8 million barrels to 122.5 million barrels, just below expectations for a 1.9 million barrel increase.
The dollar retreated across the board as oil prices spiked, after geopolitical tensions jumped back onto investors' radar with news of Iran's missile tests and of an armed attack on the U.S. consulate in Turkey.
August RBOB rose 4.14 cents or 1.23 percent to $3.4045 a gallon, trading from $3.3577 to $3.4305. It struck a record $3.5927 last Thursday. August heating oil gained 6 cents or 1.57 percent to $3.8802 a gallon, trading from $3.8205 to $3.9020. It reached a record $4.1350 on Thursday.
The heating oil crack spread rose to $25.78, after ending Tuesday at $24.41. The RBOB crack spread gained at $5.80 from Tuesday's close at $5.21.
Iran, the second-largest oil producer in the Organization of the Petroleum Exporting Countries, says its nuclear program is for power generation, whereas the West fears it is aimed at making bombs.
Amid an escalating war of words with Israel, an aide to Iran's Supreme Leader was quoted on Tuesday as saying that Iran would hit Tel Aviv, U.S. shipping in the Gulf and American interests around the world if it was attacked.
Fresh concerns over supplies resurfaced after Libya said its output would fall by about 100,000 barrels per day starting the next few days due to maintenance on a pipeline.