The COVID-19 pandemic struck the United States economy with a blow unlike any other. But in a surprise twist, the number of Americans who became millionaires actually increased by another million last year.

On Thursday, new data from wealth research firm the Spectrem Group showed that the number of Americans with $1 million or more in investable assets surged to a record 14.6 million in 2021, up from 13.3 million in 2020. According to George Walper, president of Spectrem Group, 2021 ended up becoming the "strongest year ever for millionaires in all segments."

According to the report, the stock market was the single biggest reason for the growth in wealth in 2021. Despite the emergence of the Delta and later Omicron variants of COVID-19, the U.S. economy had begun entering into its recovery phase after the devastation the initial waves of the virus brought to the economy the year before. As a sign of the profitability of the stock market, Axios reported that the S&P 500 closed at an all-time high at least 70 different times in 2021, the most seen since 1995.

Beyond millionaires, 2021 saw the average incomes of American households rise to higher levels in the last decade. In a report by the U.S. Census Bureau, it found that the median household income rose from an average of $54,000 between 2011 to 2015 to $65,000 in the 2016 to 2020 period.

But for all the gains made by the average U.S. household, the bulk of the wealth generation went to the highest income brackets last year. The Spectrem Group found that the number of Americans worth $25 million or more surged by 18% translating to a record 252,000 Americans worth $25 million or more, up from 214,000 in 2020. In contrast, those with incomes between $100,000 and $1 million grew by only 2%.