FROM Auckland to Amsterdam, Sydney to San Francisco, house prices in the best locations have gone through the roof. The Economist’s new house-price index covers 22 of the world’s most vibrant cities (see table). They are home to 163m people, with an economic output equal to Germany and Japan combined. The average price of a home in these cities rose by 34% in real terms over the past five years. In seven cities it rose by more than half.

Some of this is a rebound from the global financial crisis, which started with a housing bust. Prices in our cities fell by an average of 22% in real terms, peak to trough—in Dublin by 62%, and in San Francisco by 42%. But they have since risen by an average of 56%, in real terms, from their lowest points. In 14 cities prices are above their pre-crisis peak—by an average of 45%.

Before the crisis, city and national prices broadly rose in tandem. They fell together, too, after the bust. But when they started to rise again, they did so on average twice as fast in our cities as nationally. Moreover, according to the IMF house-price inflation in capital cities is increasingly synchronised.

To gauge whether house prices reflect fundamentals or froth, The Economist has compared them with rents and median household incomes. If prices rise faster in the long run than the revenue a property could generate or the earnings that service mortgages, they may be unsustainable. Or, at least, incomes or rents will eventually have to rise.

Taking the average ratio over the past 20 years (or more if data exist) as “fair value”, national house prices in Australia, Canada and New Zealand have been more than 20% above fair value compared with income and 30% above fair value compared with rents for the past three years. They have now hit 40% above fair value for both metrics. Data for rents at the level of cities are lacking. But compared with long-run median incomes, prices appear even bubblier at city level than nationally.

Prices in Vancouver are 65% overvalued by the same metric. The figures for Amsterdam, Copenhagen and Sydney are around 50%, and for London 59%, with rent consuming half of gross pay. In just four of our cities are prices at or under fair value: Tokyo, Milan, New York and Singapore.

But our index suggests that property prices may be near a turning point. The average rate of house-price inflation across our 22 cities has slowed, from 6.2% annually 12 months ago to 4.7% now. In six cities prices have fallen from recent peaks.

The three reasons why cities have experienced a property boom—and why it may now be ending—are demand, supply and the cost of money. In recent years people and jobs have flocked to the biggest cities from other parts of their own countries and elsewhere. More than a third of London’s population was born abroad. For Toronto, the share is more than half. The population of our 22 cities rose, on average, by 12% over the past decade. A further boost to demand has come from foreign investors. Auckland, London, Sydney and Vancouver have attracted large inflows, particularly from China.

But according to the Economist Intelligence Unit (EIU), our sister company, the growth in globalised cities’ population will soon start to slow. A few might shrink. London lost 100,000 people to the rest of Britain in the 12 months to June 2017, and the EIU expects its population to fall over the coming decade.

One reason people may stop flocking to cities is that they have been priced out. And cities are becoming less welcoming to foreign capital, too. Vancouver has made it harder for foreigners to buy property. Australia has increased property-transaction taxes for non-residents. New Zealand is considering a ban on foreigners buying property. Tighter capital controls in China add to the squeeze.

Second, planning restrictions, local campaigns against new developments and developers sitting on land they think will rise in value have conspired to make new housing scarce. In the five years to 2016 London’s population grew almost twice as fast as its housing stock. Comparing new-builds with population growth (an imperfect measure, since household composition may change, but the best available) suggests a shortfall across ten of our cities of 28,000 homes a year in the past decade.

But the calculus here, too, may be changing. Prices seem to have climbed high enough to encourage new supply. London added 40,000 homes last year—the most for decades. New-builds have added almost a fifth to Sydney’s stock of apartments in the past three years.

Finally, loose monetary policy since the financial crisis has made mortgages extremely cheap. This has “super-charged” prices, says Liam Bailey of Knight Frank Global Research, a property consultancy. Cheap money has also lowered bond yields, pushing investors into other assets, including property. As central banks tighten, servicing a property loan will become more expensive and fewer investors will seek alternatives to fixed-income assets.

London, vulnerable because of Brexit, may be a bellwether. Agents say developers have started to offer discounts of as much as 10% to close sales. As demand weakens, supply strengthens and mortgage rates rise, the bull run in global cities’ housing may be drawing to an end.

Explore the data for 44 cities in our interactive house-price index