A judge has accepted the California city of Stockton's bankruptcy application, making it the most populous city in the U.S. to enter bankruptcy.

U.S. Bankruptcy Judge Christopher Klein said the bankruptcy declaration was needed to allow the city to continue to provide basic services.

"It's apparent to me the city would not be able to perform its obligations to its citizens on fundamental public safety as well as other basic government services without the ability to have the muscle of the contract-impairing power of federal bankruptcy law," Klein said Monday.

The city of nearly 300,000 people has become emblematic of government excess and the financial calamity that resulted when the nation's housing bubble burst.

Its salaries, benefits and borrowing were based on anticipated long-term developer fees and increasing property tax revenue. But those were lost in a flurry of foreclosures beginning in the mid-2000s and a 70 per cent decline in the city's tax base

The city's creditors wanted to keep Stockton out of bankruptcy — a status that will likely allow the city to avoid repaying its debts in full.

They argued the city had not cut spending enough or sought a tax increase that would have allowed it to avoid bankruptcy.

City accumulated nearly $1B in debt

Matthew Walsh, an attorney for the bond holders, declined to comment after Monday's ruling.

Attorneys for the city said the city's budget and services had been cut to the bone.

"There's nothing to celebrate about bankruptcy," said Bob Deis, Stockton's city manager. "But it is a vindication of what we've been saying for nine months."

The Chapter 9 bankruptcy case is being closely watched nationally for potential precedent-setting implications.

The $900 million that Stockton owes to the California Public Employees' Retirement System to cover pension promises is its biggest debt. So far Stockton has kept up with pension payments while it has reneged on other debts, maintaining that it needs a strong pension plan to retain its pared-down workforce.

The creditors who challenged Stockton's bankruptcy petition are the bond insurers who guaranteed $165 million in loans the city secured in 2007 to pay its contributions to the CalPERS pension fund. That debt got out of hand as property tax values plummeted during the recession, and money to pay the pension obligation fell short.

Legal observers expect the creditors to aggressively challenge Stockton's repayment plan in the next phase of the process.

By 2009 Stockton had accumulated nearly $1 billion in debt on civic improvements, money owed to pay pension contributions, and the most generous health-care benefit in the state — coverage for life for all retirees plus a dependent, no matter how long they had worked for the city.