Fewer Mainers are middle class than 50 years ago, exacerbating the income gap in the state’s metropolitan areas where costs and inflation pressures vary.

In Maine, a couple making $39,000 before taxes would be middle income in the Lewiston-Auburn and Bangor metropolitan areas, according to a Pew Research commentary released Wednesday about major trends shaping 2022. But they would be lower income in Portland-South Portland, where the middle-income level begins at $41,000.

Upper income starts at $115,000 in pay in Lewiston-Auburn and Bangor — representing 12 percent of the population in each area. But that is still considered middle-income in Portland-South Portland, where upper-income earnings start at $125,000.

Nationally, only 50 percent of Americans were middle class in 2021 compared with 61 percent in 1971. At the same time, the median incomes for upper-class households rose considerably faster than those for middle- and lower-income households, with 21 percent of households considered upper-class compared with 14 percent five decades ago.

The median pay of middle-income American households in 2020 was 50 percent higher than in 1970 — just over $90,000 compared with approximately $60,000, as measured in 2020 dollars. The gains were realized slowly, Pew said, but for the most part they grew steadily, except for the period from 2000 to 2010 when incomes fell across the board.

The median pay for lower-income households across the nation has grown more slowly than that of middle-income households over the past 50 years. Along with that, the share of U.S. income held by the middle class is shrinking along with the number of those households. In 1970, they held 62 percent of aggregate U.S. income, but that fell to 42 percent in 2020.

Upper-income households increased their share of the country’s income from 29 percent in 1970 to 50 percent in 2020 while lower-income households saw their share nudge down from 10 percent to 8 percent.