Let me tell you how the meltdown in the Chinese stock market is going to end. No, I don’t read or speak Chinese, I’ve never been to China, and I’ve never studied Chinese history or culture. But despite this — or maybe because of it — I think I can give you a good idea of how things are going to play out in the Chinese market.

It’s going to end horribly for average Chinese people who borrowed heavily to buy stocks because everybody “knew” that that was the way for the masses to make their fortunes. But it will end in a vastly better (though probably not great) way for big, powerful financial institutions and rich, powerful insiders.

Given my lack of expertise in things Chinese, why do I think I know this? Because it’s a replay of the show we saw a decade ago in the United States. It’s called the housing bubble.

You remember the housing bubble, don’t you? Millions of Americans got it into their heads that it was a great idea to hock themselves up to their eyeballs to buy houses they couldn’t afford. They knew — or thought they knew — that house prices would only go up, because they had been going up for years.

It also meant that if people already owned houses whose value exceeded the mortgage on them, it was smart to borrow out their equity, live above their means, maybe buy another house or two, and watch housing prices keep on rising and making them rich.

Reading articles about average or nearly poor Chinese people borrowing heavily to buy stocks reminds me of what we used to see in the United States at the height of the housing bubble: average people taking on tons of debt, getting rich on paper (briefly) as the value of what they owned rose — and suddenly getting clobbered when prices fell sharply.

The parallels aren’t perfect, but they’re pretty close. The Chinese stock bubble was more extreme, and hundreds of millions of new suckers were snookered. The U.S. housing bubble drew in far fewer people — if only because the United States is a smaller market and because you couldn’t really buy a house online the way that Chinese suckers could buy stocks.

In the Chinese and U.S. cases, the governments stepped in to try to mitigate the panic and to stop the financial systems from melting down.

In China, the government got banks to buy stocks to prop up the market and is now buying stocks directly. (An aside: After all these years of privatizing, wouldn’t it be ironic for the Chinese government to end up owning major institutions all over again?)

In the United States, the Treasury and the Federal Reserve made about $13 trillion of cash and loan guarantees available to prop up the system. And these days, Uncle Sam, through his captive mortgage finance firms Fannie Mae and Freddie Mac, buys the vast majority of new mortgages that come on the market when originators decide to sell them.

Most average people in the United States who fell prey to the housing bubble were left pretty much on their own to cope with the financial wreckage of their lives. And they didn’t cope particularly well, because who could?

But big, powerful institutions were propped up through direct stock purchases by the government and the Fed’s zero-interest-rate policy. Shareholders in most cases suffered heavy losses relative to peak bubble levels, but the firms are mostly still alive, the government has sold its stock in them, and they’re free to pursue their destiny, subject to new regulations.

The institutions and some of their top executives are upset about the new rules, and some of their complaints are justified. But when you look at the big picture, these institutions are alive and well in the financial sense — as opposed to the millions of average people who lost their homes and their life savings and are struggling to survive.

These firms got bailed out not because of some nefarious government plot but because the government didn’t dare let major financial institutions go into uncontrolled collapse. Given the fragility of the financial system at the time, the collapse of a major, major player could have caused “cascading failures” and ushered in Great Depression 2.0.

The same thing, I’m sure, is going to happen in China. The government will do whatever needs to be done to keep giant, powerful financial institutions alive rather than risk a total financial meltdown.

The institutions may be publicly shamed and their CEOs pilloried as a sop to the masses. But the institutions will survive. And the various big hitters and princelings (children of China’s top leaders) and other connected and powerful people may suffer a bit but will emerge substantially intact.

Meanwhile, the average Chinese stock-market suckers who bet the moon on stocks that neither they nor anyone else understood are going to be left to sink or swim. And most of them will sink.

This isn’t nice, and it isn’t pretty. It’s how the U.S. housing bubble played out, and it’s how most bubbles that snooker the masses play out. You can take it to the bank. Which, you can be sure, will still be open as long as it’s big enough for the government not to let it fail.