NEW YORK--The gap between U.S. and global oil prices narrowed Wednesday on news that the U.S. government has allowed some exports of a form of ultralight oil, a move some analysts say could lead to a broader relaxation of the country's export ban.

Light, sweet crude for August delivery rose as high as $107.50 a barrel on the New York Mercantile Exchange after The Wall Street Journal reported the news late Tuesday. Prices settled Wednesday up 47 cents, or 0.4%, at $106.50 a barrel.

Brent crude on the ICE Futures Europe exchange fell 46 cents, or 0.4%, to $114.00 a barrel.

The Commerce Department has given Pioneer Natural Resources Co. and Enterprise Products Partners LP permission to ship a type of ultralight oil known as condensate to foreign buyers. The buyers could turn the oil into gasoline, jet fuel and diesel.

The U.S. has had a ban on crude-oil exports since the 1970s, but producers have lobbied to lift the ban in recent months as U.S. production continues to grow.

News of the ruling raised some market watchers' expectations that the federal government is open to further easing the export ban, allowing producers to sell U.S. oil at world prices, which are higher than U.S. prices.

"We view the expanding definition of refined products as a positive, and a step closer to greater export opportunities," said Morgan Stanley analysts in a note Wednesday.

U.S. oil prices briefly ticked lower in morning trade after a weekly government report showed crude stockpiles rose by 1.7 million barrels. Analysts surveyed by The Wall Street Journal had expected an average decline of 1.2 million barrels in the week ended June 20.

But prices soon recovered, in part because refineries operated at a much higher rate than analysts had expected.

"Historically, this is the time of year that refiners really crank out in preparation to supply for the summer driving season," said Kyle Cooper, a managing partner at IAF Advisors in Houston.

Refineries ran at 88.5% of capacity in the week, versus analysts' forecasts of 87.9%.

The gap between the benchmark U.S. and global contracts narrowed from $8.43 a barrel on Tuesday to $7.50 a barrel, the narrowest price difference since June 16.

The market is "waiting to see basically what shoe is going to drop next," said Gene McGillian, broker and analyst at Tradition Energy in Stamford, Conn. Conflicts in Ukraine and Iraq have buoyed oil prices with the threat of supply disruptions, but those risks appear to be priced in, Mr. McGillian said.

"We might need to see an escalation of fighting in either of the regions" before prices move much higher, he said.

Gasoline for July delivery settled down 3.31 cents, or 1.1%, at $3.0927 a gallon, while July diesel fell 1.18 cents, or 0.4%, at $3.0298 a gallon.

(Daniel Huang contributed to this article.)