Japan has so far been spared the impact of deteriorating global economic conditions thanks in part to a recovery in services sector activity following the country's delayed reopening from the COVID-19 pandemic and as the central bank maintains ultra-loose monetary policy.

But signs of a slowdown in U.S., European and Chinese growth cloud the outlook for the export-reliant economy.

"The current production sentiment is still bearish due to ongoing concerns about the downturn in overseas economies," a Ministry of Economy, Trade and Industry Official told reporters.

Factory output fell 0.4% in April from the previous month on a seasonally adjusted basis. The contraction dashed economists' median market forecast for a 1.5% gain.

Output of semiconductor-manufacturing equipment fell 24.6% while flat panel manufacturing equipment dropped 66.6%.

A METI official said U.S. export controls to China were not a factor in the decline in chip-making equipment shipments.

The drop in domestic and overseas orders contributed to the decrease in chip-making equipment, whereas falling demand for smartphones and vehicle equipment affected flat panel-making equipment.

Manufacturers surveyed by the METI expect output to increase 1.9% in May and 1.2% in June as easing supply parts shortages and other factors lift output of transportation and production machinery.

Still, the METI official said there is a risk of downward adjustment in production plans due to overseas weakness.

"Based on the forecast index, production is likely to be significantly reduced in May," said Kota Suzuki, economist at Daiwa Securities. "With weak global demand for goods, production will likely remain weak for some time."

Separate data also showed Japanese retail sales rose 5% in April from a year earlier, missing forecasts for a 7% gain.

Compared with the previous month, retail sales contracted 1.2% in April, following a 0.3% rise in March, the data showed.

(Reporting by Satoshi Sugiyama; Editing by Chang-Ran Kim, Christian Schmollinger and Sam Holmes)