Oil rebounded on Friday, led by the biggest surge in gasoline futures this year as a string of refinery outages stoked concerns about fuel supplies in the heart of the U.S. summer driving season.

News of unexpected glitches at two more refineries along the Atlantic coast added to a string of issues this week across North America, adding more fuel to a 15 percent surge in gasoline this month, the biggest such gain since March 2011.

The focus on fuel supplies extends a rally that kicked off in U.S. crude markets as traders braced for tightening U.S. Midwest supplies. Data this week showing higher U.S. gasoline demand and a record drop in crude stocks stoked gains, pushing U.S. crude futures to their highest since March 2012 on Thursday.

"We're hearing about a lot of refining issues and this comes as oil prices came off that 15-month high," said Phil Flynn, analyst at the Price Futures Group in Chicago.

"Put it all together and I think you're seeing some panic buying by the wholesalers afraid they're going to run out of supply."

The gasoline gains helped revive the rally in crude prices, which had fallen on Thursday as traders took a breather. Brent crude for August rose $1.08 to settle at $108.81 a barrel, while U.S. crude settled up $1.04 at $105.95.

Both benchmarks continued to edge up in after-settlement trading.

RBOB gasoline futures jumped more than 12 cents in intraday trading. Front-month gasoline futures hit highs of $3.1455 per gallon before settling at $3.1175.

Until Thursday, U.S. crude had been outperforming Brent for nine of 10 sessions, narrowing Brent's premium to U.S. crude <CL-LCO1=R> to a 2-1/2 year-low of $1.32 at one point before widening back out to close at $2.82.

The spread settled today little-changed at $2.86.

Rallying RBOB and U.S. crude showed signs of being overbought. Front-month RBOB reached 76 on the Relative Strength Index, while U.S. crude rose to over 71. A reading over the 70 level signals a commodity has been overbought.

With strong demand in recent weeks, buying picked up on news of refinery problems, many around gasoline-making units that have been running overtime. U.S. refinery production last week was the highest in six years, data showed.

On the Atlantic Coast, large refineries in Philadelphia, New Brunswick and Newfoundland shut or slowed gasoline units due to unexpected glitches, specialist news publisher Energy News Today Inc. reported.

Valero Energy Corp said a gasoline-producing unit at its 290,000-barrel-per-day Port Arthur, Texas, refinery, would begin an orderly shutdown for work on Friday. The company could not estimate the duration of the shutdown.

On Thursday, BP was shutting one of two small crude distillation units for a planned overhaul at its 405,000 barrel per day (bpd) Whiting, Indiana refinery, according to sources familiar with the refinery's operations.

Supply concerns supported Brent after a report that North Sea oil output from the main British and Norwegian streams will fall by 6.6 percent in August from July due to seasonal maintenance. On Thursday, Shell Nigeria shut its Trans Niger pipeline due to a leak.

Lingering worries that violence in Egypt could disrupt supply through the Suez canal also helped underpin prices.

These factors outweighed concern about the demand outlook in China, while the prospect of growing non-OPEC supply offset lower inventories in the United States. Non-OPEC supply is set to grow at the fastest pace in decades next year, the International Energy Agency (IEA) said on Thursday.