IN 2010 the demoralised police of Stockton mounted a roadside sign warning visitors that they were entering the state's second most dangerous city. “Stop laying off cops!” the billboard urged. The fiscally troubled city of 290,000, in California's depressed Central Valley, was slashing spending and cutting services in order to meet pension and health-care obligations. Violent crime had soared.

Two years later, with crime still sky-high and city services even leaner, Stockton has given up. On June 26th, after months of closed-door negotiations with its creditors failed, the city council endorsed a budget plan to file for bankruptcy. The biggest municipal insolvency in American history will hit bondholders as well as former public workers whose health-care costs the city had covered. At the budget meeting former city workers with chronic medical conditions made heartfelt pleas to find another way out. But there were no more options.

“Stockton is a cautionary tale about what happens if you don't make dramatic fiscal changes to react to the broader economic picture,” says Chris Hoene of the National League of Cities, a think-tank in Washington DC. In the mid-1990s house prices soared and taxes flooded in. The city accumulated obligations to its workers and made rash spending pledges. When the market went sour in 2007-08 Stockton was left more exposed than most. Revenues dried up. As unemployment climbed above 20%, its foreclosure rate became one of the highest in the nation, where it remains.

How many more Stocktons will America see? Perhaps fewer than some expect. “A great untold story is that a lot of cities are making dramatic decisions to bring their long-term fiscal solvency into line”, says Mr Hoene. Most municipalities were not as badly hit as Stockton, and so have more time to act on employee and retirement costs. Recent votes to cut pension benefits in San Jose and San Diego point to a growing reformist mood among some citizens.

But in some respects Stockton is not alone. Like many Californian cities, notes Kevin Klowden of the Milken Institute in Los Angeles, it handed management of its pensions to CalPERS, a statewide fund. This locked it into obligations that reduced its budgetary autonomy. Even now it has no plans to cut pensions, for fear of incurring costly lawsuits. Other cities face similar difficulties, and demography is not on their side. Like Greece in the euro zone, Stockton represents a difference of degree, not of kind.