Socorro Muñoz fled indoors as the laurel-lined square outside her shop became a public execution ground one sunny afternoon in early August.

“I didn’t want to see,” the 62-year-old storekeeper explained as she relived the moment a tide of Latin American lynchings swept into Tepexco’s picturesque Plaza de la Constitución, leaving seven alleged kidnappers dead.

Witnesses say many in this farming community felt differently and had packed the square to watch a massacre they call simply “los hechos” or “the events”.

The dead included three suspected gang members – one a teenager – who were dragged from a local police station, interrogated and strung up from a rusty yellow basketball hoop as the crowd bayed for justice, and for blood.

“My goodness, the 16-year-old kid, they hanged him and then brought him down – but he was still breathing. He was still alive,” Muñoz recounted in horror. “And when the people saw, they started shouting: ‘Put him up again! Put him up again!’ And so they put him up again. It was terrible. We’ve never seen anything like this.”

The lynchings, which took place in the Mexican state of Puebla on 7 August, were the latest expression of a regional malady blighting countries from Bolivia to Brazil, whose far-right president, Jair Bolsonaro, recently declared criminals should “die in the streets like cockroaches”.

Most weeks Latin American newspapers feature chilling tales of mob justice, often committed by otherwise law-abiding citizens and increasingly coordinated on social media and filmed on smartphones. In one recent case in the Brazilian Amazon, vigilantes smashed their way into a police station with sledgehammers in search of a suspected killer, before hacking him to death with machetes and scythes.

But Mexico, which last year registered a record 35,964 murders and where only a tiny fraction of crimes are solved, has been particularly affected.

The number of lynchings almost tripled here last year, jumping from 60 incidents in 2017 to 174 – 58 of which resulted in deaths. In the first half of this year that trend has continued with security expert Eduardo Guerrero counting at least 42 killings.

“It is truly alarming,” said Elisa Godínez Pérez, a Mexican anthropologist who studies lynchings. “There are regions like Puebla where the situation is practically out of control.”

Godínez, a postdoctoral fellow at the National Autonomous University of Mexico, said police inefficiency, a failing justice system and the rapid spread of organised crime had created the perfect “breeding ground” for vigilante justice in marginalised communities such as Tepexco.

Preyed on by criminals, ignored by the state and with little recourse to justice, residents of such areas felt “exposed and shaken” – and felt they had little option but to take the law into their own hands.

There is no escaping the neglect in Tepexco, a 3,000-strong community of corn and sorghum farmers that still bears the scars of Mexico’s last major earthquake in September 2017.

Almost two years later its two Catholic churches still lie in ruins, condemned buildings have yet to be demolished and the primary school has not been rebuilt. Around 200 children study in a cluster of portable buildings that look out on to Tepexco’s improvised execution ground.

One of the ruined churches in Tepexco, which has still not being rebuilt two years after an earthquake. Photograph: Emilio Espejel/The Guardian

“They have forgotten us here,” complained Jesús Vargas, a local councillor, during a tour of Tepexco’s decaying infrastructure.

Locals accuse security officials of abandoning them too, and complain of a wave of kidnappings, robberies and murders targeting local farmers and ranchers that the government has failed to prevent.

This month’s lynching was in response to a recent attempted abduction.

“We have a government that doesn’t work, that has forgotten us – that is why the citizens enforce justice with our own hands,” said Muñoz. “Because we no longer believe in the justice system. We no longer believe in the authorities … that is why this happened. It’s not that we are evil.”

The corpses had been cleared from the square by the time a convoy of bulletproof SUVs swept into Tepexco on the Sunday morning four days after “the events”.

Puebla’s state governor, Miguel Barbosa, was part of the convoy, on a rare visit to condemn the lynchings but also to comprehend what he calls an inevitable response to “institutional abandonment”. Dozens of heavily-armed security forces were also deployed in the town.

“We view what happened … as the reaction of a people who are fed up,” the governor, an ally of Mexico’s leftist president Andrés Manuel López Obrador, told an emergency “rule of law” assembly, to loud applause.

“Taking justice into our own hands is a way of responding [to crime],” Barbosa said. “But it is not legal and you must understand and accept this. Such events … must not repeat themselves in any part of Puebla. That is why we need a public security system that is efficient and effective and … protects you.”

Residents of the town walk home after a speech by the state governor, Miguel Barbosa. Photograph: Emilio Espejel/The Guardian

Once the governor had departed, without visiting the site of the killings, officials downplayed their significance, claiming the vigilantes had hailed from neighbouring towns.

“Tepexco is a tranquil, peaceful place,” insisted Porfirio Valentín Luna, the government secretary for the area. Valentín regretted that children had seen their playground turned into public gallows. “Unfortunately, the kids saw these lamentable events,” he said. “It was unavoidable.”

But many residents were unrepentant. “People have had enough and this is the only way they have to defend themselves,” one local businessman, who asked not to be named, declared, calling the lynching not “one person’s decision, but the decision of all the people”.

The man grew agitated as he described the abandonment he claimed justified the executions.

“If someone comes along and wants to kill your family, you will defend them – tooth and nail, by any means necessary – and you won’t think twice. The people here are the same. We are people of peace,” he insisted. “But if these people come back, we will do the same again.”