The biggest coming threat to humanity’s prosperity and well-being may come from an unexpected corner—people living longer, and not having enough kids.

As mankind becomes more prosperous and healthier, rapid aging of our societies is emerging as a global risk that poses many challenges.

“As the population shifts grayer, potential consequences include higher dependency ratios, rising healthcare costs, and shifting economies and cities,” said Jeff Desjardins, editor of Visual Capitalist.

He shared two animated maps that show how quickly populations in the U.S. and Europe are aging. By 2060, the average age in most countries in North and Latin America will be forties.

In Europe, it will be forties and fifties.

In the U.S., the population of citizens older than 65 years is expected to almost double from 48 million to 88 million over the next 30 years, while birth rates are not keeping up.

Kimberly-Clark Corp. KMB, -0.44% , whose portfolio of brands include Huggies and Pull-Ups, recently blamed record low birthrates in the U.S. and Korea for tepid sales.

Aperion Care, an operator of assisted living facilities operator, published an infographic, shared by Visual Capitalist earlier this year, that showed at least 14 states where the cost of supporting the elderly will rise in the near term.

Aperion Care

Meanwhile, recent data from Bank of America Global Wealth & Investment Management and U.S. Trust show that federal spending on health-care programs has risen steadily over the past decade, as illustrated in the chart below.

Bank of America Global Wealth & Investment Management and U.S. Trust

The implications of a society where a significant number of its citizens are entering middle age or are about to retire is that it will be a challenge for employers to fill those vacancies with younger workers. It will also be a drain on the national pension system, as there will be more people drawing from it than contributing.

The growing number of senior citizens in Japan, where the median age is 46.9, has been blamed for the country’s economic stagnation in recent years, prompting Taro Aso, the finance minister, to suggest that the elderly should “hurry up and die.”

Living longer may be a good thing for those healthy and wealthy enough to enjoy an extended retirement... but, for the global economy, it appears that too much of a good thing may also be a demographic time bomb.