By Daniel Leussink

TOKYO (Reuters) – Japan’s factory output shrank for the first time in three months in December as a decline in machinery outweighed a small rise in car production, casting a cloud over the strength of the economic recovery.

Retail sales posted their third straight month of year-on-year gains in December as low coronavirus cases encouraged shoppers. Record infections this month driven by the Omicron variant of the virus, however, are expected to have hit consumer sentiment.

Factory production lost 1.0% in December from the previous month, pulled down by a decline in output of general-purpose and production machinery, including chip-making equipment.

That meant that output, which came in weaker than a 0.8% decline forecast in a Reuters poll of economists, dropped for the first time in three months.

The data showed output growth of cars and other vehicles slowed to 1.5% from the previous month in December, much weaker than the 43.7% surge in November and a 15.9% jump in October.

Major Japanese automakers are still struggling with chip shortages.

Toyota Motor Co, the world’s biggest car seller, said this month it expected production to fall short of an annual target of 9 million vehicles for its current business year that runs until the end of March due to the drag from the chip shortage.

Manufacturers surveyed by the Ministry of Economy, Trade and Industry (METI) expected output to grow 5.2% in January and 2.2% in February.

The government kept its assessment of industrial output unchanged, saying it was showing signs of picking up.

Separate data showed retail sales were weaker than expected, rising 1.4% in December from a year earlier, which was smaller than the median market forecast for a 2.7% rise.

That marked the third straight month of increases for retail sales, which were lifted by stronger demand for general merchandise and food and beverages.

(Reporting by Daniel Leussink; Additional reporting by Yoshifumi Takemoto; Editing by Sam Holmes)