The result is that China now faces a debt problem and an overcapacity problem. Goldman Sachs estimates that the amount of debt in the Chinese economy jumped to 235 percent of gross domestic product in 2015, from 130 percent in 2008. At its current trajectory, Goldman analysts say that number could rise to 344 percent of G.D.P. by 2020.

The bills for that debt and investment binge are now coming due, including human costs that merit a compassionate response. Reducing industrial production could force five million to 10 million workers from their jobs, says Scott Kennedy of the Center for Strategic and International Studies in Washington. Banks and other investors may have to write off or restructure tens of billions of dollars in loans and bonds.

To help affected workers, China needs a stronger social safety net — retraining people for jobs in the service sector, providing generous pensions to workers close to retirement age and relocating workers in hard-hit areas to cities and towns where jobs are more plentiful. Increased spending on health and education would improve social services and create jobs. Over all, these policies should make it easier for provincial and local governments to shut down unprofitable enterprises.

On the financial side, China needs a more effective process for companies to restructure debts, merge with other businesses or liquidate their assets. The current bankruptcy system is so inefficient that many smaller businesses that fail simply disappear without settling their debts. State-owned banks keep ailing companies, some government owned, alive by rolling over their loans simply because managers do not want to acknowledge losses.

There have been signs of progress in recent months. Some state-owned businesses have defaulted on bond payments, suggesting that the government will not prop up failing companies in perpetuity, which is encouraging. But the defaults have also unnerved investors, because they cannot easily turn to bankruptcy courts to swap their debt for equity or recoup at least some of their money through negotiations with management.