Oil surges 10.3% to $42.56 a barrel; best day since March 2009

Oil rocketed more than 10 percent higher on Thursday, posting its biggest one-day rally in years, as recovering equity markets and news of diminished crude supplies set off a short-covering surge by bearish traders.

Snapping back fiercely from a deep two-month slump that reached 6½ year lows this week, oil climbed as world stock markets rose on hopes Chinese government measures to stimulate the economy would pay off, while the dollar strengthened as risk aversion eased.

U.S. crude was up $3.96, or 10.3 percent, at $42.56 a barrel, marking its best day since March 2009 when it soared 11.1 percent.

Front-month Brent, the global oil benchmark, was up $4, or 10 percent, at $47 a barrel.

The rally was aided by news of a force majeure on Nigerian oil exports declared by Shell and private data indicating more drawdowns in crude this week at Cushing, Oklahoma, traders said. A big upward revision in second quarter U.S. economic growth helped.

Read MoreSaudi Arabia hangs on with cheap oil—but for how long?

It is on track for the biggest one-day gain for the contract since late January, when Brent ripped off six-year lows to rise by nearly $10 in three days, the start of a recovery that stabilized prices through the second quarter. Brent hasn't risen by more than 8 percent in a day since the financial crisis.

Shell declared force majeure on Bonny Light crude oil exports on Thursday following the shutdown of Trans Niger Pipeline and Nembe Creek Trunkline, which can carry around 180,000 barrels per day (bpd) of crude.

Oil workers in Midland County, Texas
Mira Oberman | AFP | Getty Images
Oil workers in Midland County, Texas

SHORTS RUN FOR COVER

Brent, the global benchmark for oil, lost about $5 a barrel, or 14 percent, over the past six sessions on worsening fundamentals from a supply glut as well as weak technicals.

Since July, as oil prices embarked on a second steep decline, big funds and speculators nearly trebled their gross short positions in U.S. crude oil futures and options to more than 160 million barrels, just short of a record 180 million barrels in March, according to regulatory data.

Read More Traders bet on dividend cuts for these oil stocks

Dealers have been bracing for that to unwind, with some warning that the scramble to exit those trades could be fierce.

"It's the squeeze on short-sellers that we've been anticipating after the oil markets saw panic selling and capitulation trade in the $30 levels," said Chris Jarvis, analyst at Caprock Risk Management in Frederick, Maryland.

"Couple this with strong continued demand for gasoline and solid GDP numbers out of the U.S., and China's actions to reinflate their economy with a very shorted market, the near-term bounce we have been calling for appears to be working out."

U.S. nationwide crude oil stocks unexpectedly fell by more than 5 million barrels last week, and data from industry group Genscape showed that inventories in Cushing, Oklahoma, declined by another nearly 400,000 barrels since last Friday.

Even so, most analysts were pessimistic that oil could maintain its trek higher.

"The trend is strong and down. However, do not be wrong-footed by a correction higher," PVM Oil Associates technical analyst Robin Bieber said. "Few markets head forever in one direction with no respite."

Read MoreWhat West Texas producers are saying about $40 oil

Even the most bullish forecasters are conceding that oil prices are unlikely to stage a significant rebound soon. On Wednesday, Standard Chartered slashed its 2016 Brent crude oil forecast by $20 to $63.

Deferred contracts for next year and beyond, which had at times led the recent selloff, recovered in tandem with near-term futures, maintaining the curve's shape in a further sign that Thursday's trade was predominately short-term speculators.

Near-time spreads were little changed, while December 2015 gained nearly 8.5 percent and the December 2016 contract surged by more than 6 percent.