By Jason Douglas and Wiktor Szary

LONDON -- Bank of England Gov. Mark Carney said Tuesday that inflation in the U.K. is set to accelerate as data showed the prices charged by companies at the factory gate rose in October at the fastest annual rate for more than four years.

In testimony to lawmakers, Mr. Carney said that the fall in the pound since the country voted to leave the European Union in June means households can expect higher prices in the months ahead. Consumer-price inflation unexpectedly slowed in October, but BOE officials expect it to accelerate rapidly in early 2017 and surpass its 2% annual target by the middle of the year.

"Unfortunately, inflation is going to go up. That's theconsequence of a very large move in the exchange rate," Mr. Carney said.

The U.K.'s Office for National Statistics said Tuesday that British producer prices rose 2.1% on the year in October, the fastest annual rate of growth since April 2012.

The pickup came after a surge in input costs from a weaker pound, which was 18.5% lower against the currencies of the U.K.'s major trading partners in October than a year earlier. Input prices rose 4.6% between September and October -- the fastest monthly rate of growth on record -- and were 12.2% higher on the year. Two-thirds of British firms' raw materials are imported, the ONS said.

The acceleration in wholesale prices hasn't yet fed into a sustained pickup in the prices faced by consumers, with annual consumer-price inflation slowing to 0.9% in October from 1% in September, the ONS said, reflecting weaker gains in volatile clothing and footwear prices than a year earlier.

Yet the BOE anticipates annual inflation will accelerate rapidly as the cost pressures faced by companies feed into the broader economy and a weaker pound pushes up the cost of imported food, energy and manufactured goods.

The expected pickup presents the BOE with a dilemma. The central bank would typically raise interest rates to prevent inflation overshooting its 2% target, but officials believes that June's Brexit vote will likely weigh on growth, as uncertainty over the country's future ties to its biggest trading partner crimp on spending, investment and hiring.

Faster inflation on its own may drag on growth by squeezing consumer spending.

In his testimony, Mr. Carney reiterated earlier guidance that officials are prepared to raise borrowing costs to restrain too-rapid a pickup in inflation -- or to cut them again if the economy weakens.

The BOE's rate-setting panel in August cut the central bank's benchmark interest rateto 0.25% as part of a package of measures to cushion the economy from the surprise referendum result.

Write to Jason Douglas at jason.douglas@wsj.com and Wiktor Szary at Wiktor.Szary@wsj.com

(END) Dow Jones Newswires

November 15, 2016 10:58 ET (15:58 GMT)

Copyright (c) 2016 Dow Jones & Company, Inc.