In London, August Brent crude futures rose $5.74 to $140.05 on the ICE Futures Exchange.
Chakib Khelil, president of the Organization of the Petroleum Exporting Countries, said he believes oil prices could rise to between $150 and $170 a barrel this summer before declining later in the year. Khelil said he doesn't think prices will reach $200 a barrel.
Khelil joins a long list of forecasters who have made bold oil price predictions this year. Each new forecast—such as Goldman Sachs' recent prediction that prices could rise as high as $200—causes a jump in prices as speculative buyers are drawn into the market.
Meanwhile, the head of Libya's national oil company said the country may cut crude production because the oil market is well supplied, according to news reports.
"Shokri Ghanem, the nation's top oil official, declined to say when a decision would be made on whether to lower production, or give any indication of the size of the cut under consideration," said Addison Armstrong, director of market research at Tradition Energy in Stamford, Conn., in a research note.
Oil's move above $140 a barrel was the first for what's known as a front-month crude contract, or the contract with the earliest expiration date.
The previous trading record for a front-month contract was $139.89, set by the July contract on June 16.
Oil's record surge came late in the day on no new news, analysts said, suggesting late-session position squaring by investors.
"A lot of volume comes in the last 45 minutes (of trading)," said Jim Ritterbusch, president of energy consultancy Ritterbusch and Associates in Galena, Ill.
Oil futures were also rising as investors reassessed comments the Federal Reserve made Wednesday when it held a key interest rate unchanged. Many investors who had expected the Fed to raise interest rates in August now think a rate hike is unlikely until after the November election or next year, said James Cordier, president of Tampa, Fla.-based trading firms Liberty Trading Group and OptionSellers.com.
"Right now, the market's viewing the Fed as powerless," said Phil Flynn, an analyst at Alaron Trading in Chicago.
Interest rates affect the dollar; many analysts believe the Fed's rate cutting campaign, which began last September, had much to do with weakening the dollar against the euro and sending oil prices skyrocketing. Investors buy commodities such as oil when the greenback is falling. Also, a weaker dollar makes oil less expensive to investors dealing in other currencies.
The dollar slid against the euro after the Fed's comments Wednesday, and was down again on Thursday.
Retail gas prices, meanwhile, were unchanged overnight at a national average of $4.067, according to a survey of stations by AAA, the Oil Price Information Service and Wright Express. Gas prices have retreated slightly from a record of $4.08 set June 16, but are unlikely to fall much more as long as crude oil remains in its recent range between roughly $131 and $140.
If oil extends its gains above $140, gas prices could rise to $4.25 in short order, Cordier said.
In other Nymex trading Thursday, July gasoline futures rose 10.84 cents to $3.5025 a gallon and July heating oil futures rose 14.08 cents to $3.89 a gallon. The expiring July natural gas futures rose 37.7 cents to $13.13 per 1,000 cubic feet. Trading in expiring contracts is often volatile.