Oil fell on Wednesday for the first day in five as a rally that powered prices to three-month highs near $83 a day earlier lost steam, with little reaction to an attack on Iranian President Mahmoud Ahmadinejad.

Analysts said the market was cautious on moving on the initial reports of the attack.

Prices haven't moved today but we've just had a very strong rally, said Paul Harris, head of natural resources risk management at Bank of Ireland. Geopolitical risk from the Middle East is broadly priced in. I expect that any backlash there might be from Ahmadinejad will be far more important to the oil market than the initial attack itself, he added.

U.S. crude for September fell by 53 cents to $82.02 a barrel by 5:32 a.m. ET, after touching $82.64 on Tuesday, the highest intraday price for a front-month contract since May 5. On Monday it topped $80 for the first time in three months.

Front-month ICE Brent dropped 74 cents to $81.4.

The dollar hovered near a three-month trough against the euro following Tuesday's data showing U.S. consumer spending and incomes were flat in June and the index for pending sales of previously owned homes fell to a record low.

U.S. INVENTORIES

I don't think there is a fundamental justification for prices above $80, said Christophe Barret, oil analyst at Credit Agricole CIB in London.

The increase in gasoline stocks and lower than expected fall in crude stocks announced by the American Petroleum Institute late on Tuesday pressured prices, he added.

U.S. Energy Information Administration government statistics on oil inventories and demand from the United States, the world's biggest oil consumer, will be published at 10:30 a.m. ET.

If we have a relatively slight drop in crude oil stocks it would indicate that crude stocks remain at very very high levels. Barret said

China's economy will cool further in the third quarter as fiscal stimulus starts to fade and the restocking cycle draws to a close, a government think tank said on Wednesday.

A militant group linked to al Qaeda claimed that a suicide bomber from its organization was responsible for an explosion on a Japanese supertanker last Wednesday near the Strait of Hormuz.

(Additional reporting by Alejandro Barbajosa; editing by William Hardy)