Benchmark crude for December delivery rose $2.25 to settle at $81.37 a barrel on the New York Mercantile Exchange. Prices hit $82 at one point.
Gasoline futures spiked and Brent crude rose $2.45 to settle at $79.69 on the ICE Futures exchange.
The run-up in prices came within minutes of a government report showing that crude supplies in the United States are growing and that refiners are producing very little gasoline because consumers aren't using as much.
"The dollar obviously is the overriding factor," PFGBest analyst Phil Flynn said. "It's not about demand I can tell you that."
Refiners are shutting down plants, a combination of little demand and rising crude prices that wipe out profit margins.
That can have real consequences at the pump. The government reported Wednesday that gasoline supplies fell by more than 2 million barrels last week.
There is usually a lag between the direction of crude bought and sold on Nymex and the price that people pay for gasoline to fill up their cars.
Crude began to rise on Oct. 7, when a barrel cost less than $70.
Average retail gasoline prices started ticking higher one week later and a gallon has increased every day since, up about 12 cents in one week to $2.596 on Wednesday, according to auto club AAA, Wright Express and Oil Price Information Service.
A gallon is still 29 cents less than last year at this time, when gas prices were in full retreat.
There are concerns that spiking energy prices could stunt any economic recovery in Europe and the United States.