$107 a barrel Friday, as Iraq's widening insurgency fueled concerns that crude supplies from OPEC's No. 2 producer could be slowed.
After jumping over $2 on Thursday, the benchmark U.S. oil contract for July delivery rose 38 cents to close at $106.91 in New York. For the week, the U.S. benchmark rose 4.1 percent.
Brent crude, a benchmark for international oils used by many U.S. refineries, gained 39 cents to close at $113.41 a barrel in London. Brent rose 4.4 percent this week.
Oil prices have risen to 10-month highs after an al-Qaida-inspired group capturing two key Iraqi cities this week, including Mosul, which is in an area that is a key gateway for the country's crude. The group has vowed to march on Baghdad.
The violence in Iraq is mostly centered in the country's north, away from the major oil-producing regions of the south. The turmoil hasn't yet slowed exports, though it raises concerns about whether Iraq can continue rebuilding its oil infrastructure and boost output to meet global demand.
"Without the oil production from the south of Iraq, the market would be stripped of an estimated 2.5 million barrels per day," said a report from analysts at Commerzbank in Frankfurt. "The sharp price rise in the last two days shows that this oil supply is no longer viewed as secure, either."
Iraq's oil production has risen by about a fifth since 2011 to 3.3 million barrels per day, making it the second biggest producer in OPEC behind Saudi Arabia.
In other energy futures trading in New York:
— Wholesale gasoline fell 2.6 cents to close at $3.058 a gallon.
— Natural gas fell 2.3 cents to close at $4.739 per 1,000 cubic feet.
— Heating oil fell 0.1 cent to close at $2.988 a gallon.
AP Writer Pablo Gorondi contributed to this report from Budapest.