WASHINGTON — Consumers paid more to fill up their gas tanks, buy groceries and go to the hospital in January as prices on a range of items climbed.

Inflation was increasing even as the economy was slowing dramatically. The Labor Department reported its closely watched Consumer Price Index posted a gain of 0.4 percent last month. That matched the December increase and was higher than the 0.3 percent rise analysts had expected. Food costs jumped by the largest amount in 11 months.

Core inflation, which excludes food and energy, rose by 0.3 percent, the biggest jump in seven months. That increase reflected higher prices for medical care, education, clothing, tobacco and airline fares.

With the latest increase, core prices have risen over the past 12 months by 2.5 percent, far above the Federal Reserve's comfort zone of 1 percent to 2 percent gains in the underlying inflation rate. The increase in inflationary pressures comes as economic growth has slowed sharply, raising concerns the nation might be in danger of falling into a recession.