Over the past two years, Americans who own their homes have gained more than $6 trillion in housing wealth. To be clear, that doesn’t mean homebuilders have transferred to buyers $6 trillion worth of new housing, or that existing homeowners have made $6 trillion in kitchen and bathroom upgrades.

Rather, most of this money has been created by the simple fact that housing, in short supply and high demand across America, has appreciated at record pace during the pandemic. Millions of people — broadly spread among the 65 percent of American households who own their home — have gained a share of this windfall.

It’s a remarkably positive story for Americans who own a home; it’s also inseparable from the housing affordability crisis for those who don’t. For them, rents are rapidly rising. Inflation is whittling away their incomes. And the very thing that has created all this wealth has pushed homeownership as a means of wealth-building further out of reach.

That dual reality follows what has been a mass wealth creation event with few precedents in American history.

“I really struggle to come up with a parallel to this,” said Benjamin Keys, a professor at the Wharton School of Business, trying to identify a moment when this many people gained this much wealth in this little time.

In percentage terms, the stock market has risen by more during the pandemic, but fewer Americans have profited from that. During the last housing boom, the run-up in home values was similarly dizzying but limited to fewer parts of the country. And that equity largely vanished in the kind of bust that economists say is far less likely to happen this time. Perhaps a better analogy, Mr. Keys suggested, would be the 1889 Oklahoma Territory land rush, or the 1920s Los Angeles oil boom, events that abruptly changed who owned land and how much it was worth.

The $6 trillion sum, estimated by the Federal Reserve, doesn’t count all the equity in rental properties. So it’s an underestimate of the riches piling up in the housing market lately.

Hard-to-predict events, like a painful recession, could still claw back some of this total, of course. Property taxes can go up. And this wealth is not the same as having money parked in a bank account. To use it, households must sell a home or tap its value through a tool like a home-equity loan, and that’s not risk-free. But evidence shows that homeowners wield home equity in real ways — to send their children to college, to start businesses, to invest further in housing, building even more wealth.

“There’s a rosy picture and a not-so-rosy picture,” said Emily Wiemers, an economist at Syracuse University who has studied how families tap their home equity to pay for higher education. “The flip side is pretty troubling. There’s this set of kids whose parents don’t own a home and so didn’t see this increase in wealth, and also whose parents may have seen declines in income.”

The cumulative effects figure to be sweeping, and divergent: This period of rising equity will enable some families to create intergenerational wealth for the first time. It will force other families to delay homeownership for years.

It will amplify inequality, as gains go disproportionately to baby boomers (at the expense of millennials who will one day buy their homes), and to white households, who have a homeownership rate that is 30 percentage points higher than that of Black households. But Black home-owning families will benefit in particular because Black household wealth is overwhelmingly in the form of housing.

“I don’t think that there’s a viable alternative to homeownership at this point in time” in terms of building wealth, said Cy Richardson, the senior vice president for programs at the National Urban League, which promotes homeownership among Black families. “And it’s an economic disaster for Black families who are unable to achieve homeownership.”

The highest-income households, who own the most expensive homes, have seen the largest total gains. But because homeownership is so widespread in America, the poorest fifth of households have also added billions in home equity in the last two years. In percentage terms, they’ve seen the biggest increases in wealth.

Homeowners who recall the 2008 housing bust may feel nervous about all this. But this is a very different housing market, said Mark Zandi, the chief economist at Moody’s.

The bubble in the early 2000s was defined by risky lending and overbuilding. Today, home buyers are on much sturdier ground with their credit scores, conventional mortgages and pandemic savings. Today there’s also a housing shortage nationwide. And that has collided with soaring demand from historically low mortgage rates, from families in search of more space during the pandemic, and from remote workers who could relocate to more affordable places. Home values, as a result, have been up nearly everywhere (making many of those affordable places not so affordable any more).

Price growth will most likely slow now that interest rates are rapidly rising, but economists generally don’t expect prices to fall. There’s just too much demand for too little housing in America today. Rising rates will make it more expensive to access equity. But this equity, Mr. Zandi said, “will prove largely durable.”

Black Knight, a company that tracks the mortgage market, estimates that the average homeowner with a mortgage has gained $67,000 in “tappable equity” in the last two years. That’s actual cash households could access while still keeping 20 percent of the equity in their homes as lenders often require.

By that measure, the average mortgage holder in the San Jose, Calif., metro area has picked up $230,000 in two years. In Boise, Idaho, it’s $114,000. In Cleveland, it’s $27,000.

“For large swaths of U.S. households, this is great,” said Michael Lovenheim, an economist at Cornell. “And it’s not just for the super rich, and it’s not just for those who live in the big superstar cities. This is happening in Ithaca, too.”

Mr. Lovenheim has found that families that experienced higher home price growth while their children were in high school were more likely to send their children to college. And the children who went to college were more likely to attend public flagship universities than community colleges.

He and colleagues have also found that households with rising home values were more likely to have children. Work by other researchers has shown that they’re more likely to start new businesses, too.

“Is this wealth real?” Mr. Lovenheim said. “People act like it’s real.”

The first home Julio Velezon II was able to buy in 2019 in Springfield, Va., has measurably changed his life. He and his wife had their first child in that townhome. Then they were able to buy a larger single-family home in December, keeping the first home as a rental property.

Had they not bought in 2019 — before today’s home prices, and today’s rental inflation — he knows exactly how his life would be different: Not buying a home, he said, would have meant not having a son.

“I wouldn’t have felt comfortable having a kid when we were moving and renting,” said Mr. Velezon, a 35-year-old Air Force technical sergeant. “Renting is such an unknown variable — it’s at the mercy of someone else, of the market.”

Now he imagines that his 18-month-old son could live as an adult one day in one of these homes.

Similar stories are increasingly out of reach for other families who come to First Home Alliance, a housing counseling nonprofit based in Northern Virginia that helped Mr. Velezon. Today a family making $70,000 a year can’t compete for a three-bedroom in the area.

“Some of them just have to wait,” said Larry Laws Sr., the president of First Home Alliance (a nonprofit he started with his own housing wealth). “We can educate them on the process, get them fully qualified for affordability. But they cannot purchase in this area.”

They’ll wait, instead, for their incomes to rise, or for home prices to cool, or for new home building to pick up.

But going forward, Mr. Keys, the Wharton professor, worries that all this housing wealth will only reinforce aspects of the American housing market that are fundamentally problematic: that families feel they have few alternatives to build wealth, that housing must act as both shelter and financial asset, that homeowners are motivated as a result to protect that asset.

“There’s actually something that’s kind of pernicious about this,” he said. In a sense, millions of people have made trillions of dollars the last two years by doing nothing.

“But it’s worse than that,” he continued. “It’s not that they’re not doing anything; it’s that they’ve aggressively blocked development in so many places.”

This wealth has been created, he said, precisely because it’s so hard to build housing in America. And that could make the case for building more of it harder still.