Updated

High-flying oil climbed back over $50 a barrel on Thursday, with worries over the security of Nigerian supply supporting prices despite a surprise build in U.S. crude inventories.

U.S. light crude (search) traded as high as $50.10 a barrel, less than 40 cents off Tuesday's all-time record of $50.47, before falling back to just under $50. London's Brent crude was 62 cents up at $46.70.

A Nigerian rebel group's threat to launch all-out war against the government in the oil-rich delta region has kept prices boiling this week.

Mujahid Dokubo-Asari's Niger Delta People's Volunteer Force (search) agreed a truce after talks in capital Abuja on Wednesday, helping the market unravel some of its gains.

Analysts said fears still remained over the security of Nigeria's more than two million barrels per day of crude.

Peace talks continued in Abuja on Thursday, but main producer Shell said it had withdrawn more workers from the troubled region.

"The Nigerian cease-fire inspired a classic knee-jerk sell off after the European close last night, but it did not take too long for the still less than conciliatory tone of the rebel leaders to show through," said 4Cast analyst Paul Bednarczyk.

"Until and unless there is some more tangible progress on talks the crude price is likely to eat still further into the ground lost after the upside surprise on crude stocks from the U.S. agencies yesterday."

Fears for a disruption to world supply capacity, tightly stretched to accommodate the fastest demand growth in a generation, have underpinned more than 53 percent gains on crude prices so far this year.

Data from the U.S. government Energy Information Administration (search) on Wednesday showed a surprise build on crude stocks, which had been expected to fall as a result of hurricane disruption in the Gulf of Mexico.

The weekly inventory snapshot showed stocks of distillate fuels, including key supplies of heating oil, fell 1.3 million barrels to nearly five million barrels below year-ago levels.

"Although the crude stock rise in itself was bearish, other components of the report were not," said Edward Meir of Man Energy.

"For example, refinery utilization did not rise hand it hand with inventories, suggesting that the crude inventory increase was due to many refineries still not being fully operational."

The U.S. government says nearly 29 percent of Gulf of Mexico daily output is still shut in after Hurricane Ivan.

The market brushed off news that Yukos would resume full deliveries of oil to China by October 20 after a brief cut forced by a lack of cash for export fees.

Average U.S. prices this year of $39 a barrel, when adjusted for inflation, are near those of the Arab oil embargo in 1973-1974. But they remain much lower than the record $80 annual average following the 1979 Iranian Revolution.

Consumers have so far put a brave face on this year's price surge, saying only continued strength poses a serious risk to global economic growth.

European buyers have been shielded in part from dollar-denominated oil's gains by the strength of the euro. In Euro terms, oil prices have hardly advanced from their mid-2000 levels.