BEIJING—Hundreds of people angry at a debt-laden Chinese city’s plans to deal with overcrowded public schools clashed with police in a protest that shows the social tensions beneath China’s long-running local-government debt problems.

More than 600 people gathered Saturday night outside police headquarters in Leiyang to express their outrage over a plan to force some students to attend private school. Some threw water and beer bottles, bricks and firecrackers at police officers and local officials, the police said in a news release on Sunday.

“We tried to film it with our phones, but we decided to run. People were pushing each other and there was no place to go. It was terrifying,” Leiyang resident Liu Yun said. “Later, the fighting started. A bunch of children got hurt.”

More than 30 police personnel were wounded in the clash, the gate to the police compound was damaged and several cars were smashed up, according to the news release, posted on a verified police social-media account. Authorities detained 46 people believed to have led attacks on police, said.

Leiyang, which sits in coal-mining country in southern Hunan province, has seen its finances deteriorate over the past year as the coal industry went into a slump while city-backed companies racked up debts to redevelop slums and attract new businesses. In May, the city didn’t have enough money to pay civil servants, until the province dispatched emergency funds, according to the Leiyang government.