A man scaled the wall of a school building in China and sprayed a corrosive substance on the kindergartners inside — burning 51 kids and three teachers, according to new reports.

The 23-year-old suspect, only identified by his surname, Kong, cut wires and climbed over a wall into the Dongcheng Kindergarten in Kaiyuan, Yunnan province, where he sprayed sodium hydroxide on children and staff around 3:30 p.m. Monday, the South China Morning Post reported.

About 40 minutes later, Kong — who authorities believe was acting alone — was taken into custody, according to the report. Local police believe he carried out the attack “as a revenge on society,” the state-run Xinhua News Agency reported.

The dozens of students and their teachers were taken to local hospitals — where two of the injuries are considered serious but not life-threatening.

Kong bought the caustic soda online, the Kaiyuan municipal government said in a statement obtained by the Morning Post.

Exposure to sodium hydroxide can cause irritation to the eyes, skin and mucous membranes, as well as an allergic reaction, according to the Centers for Disease Control and Prevention. Eye and skin burns, as well as temporary hair loss, can also occur.

This isn’t the first time grade-school students have been targeted in China in recent years.

Back in March, a kindergarten teacher in the eastern part of the country was arrested on charges of deliberately poisoning 23 students’ food with sodium nitrite.

In January, a 49-year-old former employee at a Beijing school injured 20 children with a hammer.

Last November, a car plowed into a crowd of children outside a primary school in northeastern China, killing five people and injuring 18.

And in October 2018, a knife-wielding 39-year-old woman injured 14 children at a kindergarten in the western Chinese city of Chongqing.