(Reuters/Aly Song)

China's housing bubble is starting to pop, so, right on cue, its stock bubble is starting to re-inflate.

Now they're nowhere near their 2007 highs—in fact, they're barely halfway there—but Chinese stocks are still looking plenty frothy right now. They've actually, as BNP Paribas' Richard Iley points out, been the world's best performing asset class the last nine months, up almost 80 percent. And that's despite the fact that China's growth has slowed to a 20-year low and its industrial profits just fell 8 percent.

Why are stocks up so much if the economy isn't? Well, there aren't a lot of other places for Chinese investors to put their money. The government doesn't let them move it overseas—although some people manage to get around this by pretending to pay more for imports—and there aren't a lot of options at home. Banks are only allowed to pay people paltry interest rates, so that state-owned companies can borrow for less. And the property market, which had looked like the economy's one good store of value, has become so overbuilt that not even the government's attempts to prop it up, like making it easier to buy a second home, has stopped its boom from turning into a bust. Indeed, new home prices were down 5.1 percent in January.

So stocks have won by default, with a little help from the government. China's state media told people over and over and over again last summer that stocks looked cheap, and eventually they listened. New stock accounts, as you can see in the chart below from BNP Paribas, exploded in the last six months or so. It's gotten to the point that, unlike before when stocks were something only people who'd gone to school bought, over 67 percent of China's new stock investors have less than a high school education.

Source: BNP Paribas
Source: BNP Paribas

But it's not just dumb money that's pouring into stocks. It's dumb borrowed money, too. Margin accounts, which let you take out loans to buy stocks, more than doubled in 2014. And to give you an idea how important this has become to the market, well, just take another look at this chart. Notice how new stock accounts briefly collapsed at the start of the year? That was because the government said it wouldn't let the three biggest brokerages open any new margin accounts for the next three months, so nobody wanted to open any stock accounts at all. As a result, the Shanghai Index fell 7.7 percent in a single day. It more than bounced back, though, once people realized that they could still buy stocks with borrowed money now that China's shadow banks—basically unregulated lenders—had stopped putting money into the faltering property market and started putting it into the flaming-hot stock market instead.

The thing about bubbles is they can go on a lot longer than you think. And the longer they do, the dumber you feel for not jumping in sooner. But since no one wants to feel like a sucker, eventually everyone, or close enough to it, joins the frenzy until it really does look like "this time is different." It never is, though. Now, as long as China's interest rates keep falling, which they should for awhile, people should still be able to afford to borrow money to buy stocks with. And that could push China's stocks up a lot more, especially given that price-earnings ratios are still far below their bubbly 2007 levels. But it's not sustainable for stocks to soar at the same time that growth is drifting down lower and lower—which means, at some point, it's going to end.

The question is what will happen to China's economy if there isn't a stock or housing bubble to invest in. That's an answer we don't want to know.