FAST cars whizz around, malls are full of expensive luxuries and cranes dominate the skyline. But scratch the shimmering surface of the Gulf and you soon find countries hurting from the low oil price, currently around $40 a barrel. Growth is slowing and unemployment is rising. Policymakers even dare utter a three-letter “t” word until recently taboo: tax.

Oil is central to the six Gulf Co-operation Council (GCC) states, which have used the windfall of the past few years to spend lavishly. Unlike many oil exporters, such as Nigeria and Venezuela, they have high foreign-exchange reserves and low debts to cover short-term gaps. But public spending is generous and the private sector is heavily reliant on oil to boot. To be sustainable in an era of lower prices, the rulers must change the structure of their economies.

The IMF reckons the lower oil price knocked $340 billion off Arab oil-exporting states’ government revenues in 2015. This year is looking worse. Moody’s, a ratings agency, this month downgraded Bahrain and Oman and put on watch the other four GCC states: Saudi Arabia, Kuwait, the United Arab Emirates (UAE) and Qatar. “It’s the end of an era for the Gulf,” says Razan Nasser of HSBC in Dubai. “And we’re only just starting to see the effects.”

Oil receipts typically account for more than 80% of GCC government revenues, rising to over 90% of Saudi Arabia’s budget before the crisis. Dubai, one of the emirates making up the UAE, is an exception, with oil accounting for only 5% of revenues. That is because it has successfully diversified: tourism and services account for most of its government revenues.

Governments are reacting to the squeeze on their incomes with a mixture of strategies, drawing down reserves and taking on debt on the one hand, and imposing spending cuts on the other. Last year they made tweaks, such as curbing benefits for public servants. This year will be tougher. Oman has told all state-owned enterprises to remove perks such as cars. Qatari companies including Al Jazeera and the Qatar Foundation, a cultural organisation, have laid off employees. With such tweaks Kuwait, the UAE and Qatar, which have small populations and high foreign-exchange reserves, can get by for a decade.

But the other three states are in a trickier position. Oman and Bahrain have relatively low reserves. Oman posted a larger than expected budget deficit in 2015, at almost 16% of GDP. By the end of 2017 Bahrain’s debt is expected to reach 65% of GDP. It needs an oil price of $120 to balance its books. The two have other concerns, too. Bahrain’s Shia-majority population bristles at being ruled by a Sunni monarchy. There is a lack of leadership in Oman; Sultan Qaboos is, again, in Germany being treated for suspected cancer.

Observers are particularly concerned about Saudi Arabia, which Barack Obama will visit to meet Gulf leaders next month. It has huge foreign-currency reserves—roughly $740 billion at the end of 2014—but is drawing them down at a clip, taking out about $115 billion in 2015. At 30m, its population is the Gulf’s biggest, and it has a sprawling royal family to pamper.

Happily, predictions that the oil price will not rise quickly are focusing minds on all sorts of structural reforms. “This is good for the Gulf; it will be a rich period for policy-making,” says Nasser Saidi, an economist in Dubai. The UAE cut fuel subsidies last year, and other states are following suit. Bahrain removed subsidies on some food items. Saudi Arabia raised the cost of electricity and water. Oman is printing the cost of the fuel subsidy on household electricity bills to prepare the population for paying the whole lot.

But with real prices now near the subsidised prices, there is less room for savings from cuts than there was a few years ago. And outgoings remain high. It is not just that the Gulf states are committed to large infrastructure projects—metros, financial centres, ports and railways. They spend billions of dollars on wages and handouts to their rapidly growing populations. The relatively young states need to spend cash on education. And they are embroiled in costly wars in the region.

Making matters worse, cuts in spending affect the nascent private sectors where, apart from the UAE and Bahrain, most activity is linked to oil, such as services to the industry; and to public spending, such as construction. Economic growth is slowing. “The lack of countercyclical measures is amplifying the pain,” says Ms Nasser. Banks are getting tougher on loans just when the state wants to encourage more small businesses. By some reckonings, the private sector in the Gulf contributes less to GDP now than in earlier decades.

The GCC countries need to do much more if the books are to balance in the future. Diversification, long talked about, has to happen now, although it is harder to do it in bad times. Plans look good on paper—encouraging tourism and logistics, for example—but more uncertain in real life. Saudi Arabia is not keen on Westerners trampling around the kingdom.

A modest value-added tax, long discussed, of up to 5%, will be introduced across the region by 2018. Oman has raised corporate tax from 12% to 15%. Other states are considering taxing expatriates’ incomes. But above all, the public sector has to stop acting as the main employer. That would be a big shift. Gulf citizens have got used to earning without doing much. Private firms are not creating enough jobs to keep up with the number of young people graduating from university, and large expatriate workforces provide tough competition. Gulf rulers fear that cutting spending would alter the social contract in which largesse buys their people’s quiescence.

But they have no choice. A new generation of younger leaders, such as Saudi Arabia’s Muhammad bin Salman and Muhammad bin Zayed in the UAE, are more willing to make tough changes. The GCC states have had an amazing few years in which they built up infrastructure and saved. But they did too little to prepare for a post-oil future. Now they must catch up.