Oil prices trimmed early gains in volatile trade today after news that Iran had dashed the possibility of participating in a possible deal between OPEC and other producing countries to trim output.

Prices rose early on prospects that a deal between major exporters to cut production could help reduce one of the biggest oil supply gluts in history.

Brent hit as high as $35 a barrel, up about 25% from the 12-year lows hit last week.

But oil retraced early gains, with both contracts briefly turning negative, after the Wall Street Journal cited an Iranian oil official as saying the country would not join an immediate OPEC production cut.

The paper said Iran wants to boost crude exports by 1.5 million barrels a day.

Russia, a major non-OPEC producer, this week said it could cooperate with the Organization of the Petroleum Exporting Countries on production curbs, something it had been refusing to do for 15 years.

Brent March futures rose 51 cents to $34.40 a barrel shortly before 5.30pm Irish time.

On 20 January the contract hit its lowest since 2003 at $27.10 a barrel.

US crude rose 24 cents to $33.46 per barrel, a 0.7% gain, having hit a high of $34.40.

Moscow has been sending mixed signals, as Deputy Prime Minister Arkady Dvorkovich said on Friday the state would not intervene to balance the market.

Those comments fed growing doubts about a possible deal mentioned by Russian Energy Minister Alexander Novak on Thursday.

But a few hours later, Russia's foreign ministry said veteran minister Sergei Lavrov, who almost never comments on oil policies, would visit the UAE and Oman to discuss oil markets.

"The market has rewarded these statements about the possibility of a deal, even though I think it's ridiculous," said John Kilduff, partner at Again Capital LLC in New York.

He noted that Iran and Iraq were determined to boost production, and were unlikely to come together with Saudi Arabia, which has made no official statement on a deal, to cut OPEC output.

"This is a rally on false hopes, unfortunately."

Oil prices also drew support from weak US GDP data that raised expectations the US Federal Reserve may slow down on any planned interest rate hikes.

Some analysts said oil prices may have found a bottom and could rally as high as $45 by year-end if non-OPEC supply is reduced and global demand improves.

"With more energy companies announcing cuts and OPEC contemplating a cut, it looks like oil is forming a bottom," said Phil Flynn, an analyst at Price Futures Group in Chicago.

US shale producers have been slashing 2016 capital spending plans, with one saying prices would need to rise more than 20% just to turn a profit.

"Now the question becomes how high can they go? The charts look like a test near $40 is on the cards."