(Bloomberg) -- U.S. job openings unexpectedly rose in May, representing a pause in a recent decline that underscored a gradual slowdown in labor demand.

Available positions increased to US8.14 million from a downwardly revised 7.92 million reading in the prior month that was the lowest in three years, the Bureau of Labor Statistics Job Openings and Labor Turnover Survey, known as JOLTS, showed Tuesday. Both hiring and layoffs picked up in a sign of churn in the job market.

The median estimate in a Bloomberg survey of economists called for 7.95 million openings.

The number of vacancies per unemployed worker, a ratio the Federal Reserve watches closely, held at 1.2 and matched the lowest since June 2021. At its peak in 2022, the ratio was two to one.

The June advance in openings was driven by manufacturing, government and health care. Vacancies in accommodation and food services led all industries that declined.

Despite the increase in openings, recent data suggest the labor market is slowly cooling and looking more like the one before the pandemic. Hiring and wage gains have eased in recent months, while more people are now receiving unemployment benefits after staying historically low.

Economists expect that trend to continue ahead of Friday’s jobs report, which is expected to show employers added about 195,000 payrolls in June and the unemployment rate held at 4 per cent.

--With assistance from Chris Middleton.