WASHINGTON (AP) — Consumers spent a bit more in August than the previous month, a sign the economy is holding up even as inflation lifts prices for food, rent, and other essentials.

Americans boosted their spending at stores and for services such as haircuts by 0.4% in August, after it fell 0.2% in July, the Commerce Department said Friday. Yet much of that increase reflected higher prices, with an inflation gauge closely monitored by the Federal Reserve rising 0.3% in August, the government’s report showed.

The figures suggest that the economy is showing some resilience despite sharply rising interest rates, violent swings in the stock market, and high inflation.

Still, there were signs that rising prices are weighing on shoppers. Consumer spending, adjusted for inflation, is growing at a weaker pace. It increased at an annual rate of 2% in the April-June quarter. Yet July and August data indicate that spending growth is on track to slow to an annual rate of just 0.5% in the July-September quarter, economists said.

The economy is expected to grow in the third quarter, after shrinking in the first six months of this year. But many economists lowered their forecasts after the spending report and now expect growth will be just 1% or so at an annual rate.

Americans are also saving less in order to keep up with higher prices. The U.S. saving rate was just 3.5% in August, far below pre-pandemic levels of about 8%, Friday’s report said.

There have been other signs of consumer weakness recently, with used car seller Carmax reporting sharply lower sales in the three months ending in August. The company attributed the decline to “affordability challenges” for consumers amid high inflation and rising interest rates.

Compared with a year ago, prices jumped 6.2%, down from a 6.4% annual gain in July but not far from June’s four-decade high of 7%. The figure is lower than the more widely-known consumer price index, released earlier this month, which reported an 8.3% price gain in August from a year earlier.

The two indexes differ for several reasons. For example, the consumer price index puts much greater weight on rents and housing costs, which have been rising steadily, than the measure released Friday, known as the price index for personal consumption expenditures.

Excluding the volatile food and energy categories, core prices rose 0.6%, much faster than July’s flat reading. They increased 4.9% from a year earlier, up from July’s figure of 4.6%.

Those figures were higher than expected, and may make the Federal Reserve more likely to lift its benchmark interest rate by another hefty 0.75 percentage point at its next meeting in November. If so, that would be the fourth such hike in a row.

The inflation figures in Friday’s report echoed those released earlier this month, with core prices rising more quickly than headline inflation. Falling gas prices have reduced overall inflation, while stubbornly high costs for housing, cars, and services such as health care and hair cuts have pushed core prices higher.

Adjusted for inflation, consumer spending ticked up 0.1% last month, after falling slightly in July.

Friday’s report also showed that personal income rose 0.3% in August for the second month in a row. Adjusted for price increases, disposable income — what is leftover after taxes — ticked up 0.1%, after a hefty 0.5% gain in July.

But over a longer time frame, incomes are trailing inflation. In the April-June quarter, inflation-adjusted disposable income fell 1.5% at an annual rate.

The Federal Reserve is seeking to wrestle inflation under control with its most rapid series of interest rate hikes in four decades. It has pushed its benchmark short-term rate to a range of 3% to 3.25%, the highest since early 2008, up from nearly zero in March.

Fed Chair Jerome Powell and other officials have repeatedly underscored the Fed’s determination to bring prices down, even if their rate hikes result in layoffs and a higher unemployment rate.

The Fed intends its interest rate increases to slow borrowing and spending, which should in turn reduce inflation pressures in the economy.

Inflation has spiked globally, contributing to economic and financial turmoil in the United Kingdom, Europe, and a slew of developing countries, from Turkey to Argentina.

Also Friday, the 19 countries that use the euro currency reported that inflation spiked 10% from a year earlier, as prices for natural gas and electricity soared. European countries are struggling with an energy crunch in the aftermath of Russia’s invasion of Ukraine, as Russia has reduced its supplies of natural gas to the European Union.