QUITO, Ecuador (AP) -- Ecuador's president has declared a state of emergency in the prison system following a battle among gang members in a coastal lockup that killed at least 116 people and injured 80 in what authorities say was the worst prison bloodbath ever in the country.
Officials said at least five of the dead were found to have been beheaded.
President Guillermo Lasso decreed a state of emergency Wednesday, which will give the government powers that include deploying police and soldiers inside prisons. The order came a day after bloodshed at the Litoral penitentiary in Guayaquil that officials blamed on gangs linked to international drug cartels fighting for control of the facility.
Lasso, visibly moved by the carnage, said at a news conference that what had happened in the prison was "bad and sad." He also said he could not guarantee that authorities had regained control of the lockup.
"It is regrettable that the prisons are being turned into territories for power disputes by criminal gangs," he said, adding that he would act with "absolute firmness" to regain control of the Litoral prison and prevent the violence from spreading to other penitentiaries.
Images circulating on social media showed dozens of bodies in the prison's Pavilions 9 and 10 and scenes that looked like battlefields. The fighting was with firearms, knives and bombs, officials said. Earlier, regional police commander Fausto Buenaño had said that bodies were being found in the prison's pipelines.
Outside the prison morgue, the relatives of inmates wept, with some describing to reporters the cruelty with which their loved ones were killed, decapitated and dismembered.
"In the history of the country, there has not been an incident similar or close to this one," said Ledy Zúñiga, the former president of Ecuador's National Rehabilitation Council.
Zúñiga, who was also the country's minister of justice in 2016, said she regretted that steps had not been taken to prevent another massacre following deadly prison riots last February.
Earlier, officials said the violence erupted from a dispute between the "Los Lobos" and "Los Choneros" prison gangs.
Col. Mario Pazmiño, the former director of Ecuador's military intelligence, said the bloody fighting shows that "transnational organized crime has permeated the structure" of Ecuador's prisons, adding that Mexico's Sinaloa and Jalisco New Generation cartels operate through local gangs.
"They want to sow fear," he told The Associated Press on Wednesday, urging the government to temporarily cede control of the prisons to the National Police. "The more radical and violent the way they murder," the more they achieve their goal of control, he added.
Ecuador's president said that care points had been set up for relatives of the inmates with food and psychological support. He added that a $24 million program to address the country's prisons will be accelerated, starting with investments in infrastructure and technology in the Litoral prison.
The former director of Ecuador's prison bureau, Fausto Cobo, said that inside penitentiaries authorities face a "threat with power equal to or greater than the state itself." He said that while security forces must enter prisons with shields and unarmed, they are met by inmates with high-caliber weapons.
In July, the president decreed another state of emergency in Ecuador's prison system following several violent episodes that resulted in more than 100 inmates being killed. Those deaths occurred in various prisons and not in a single facility like Tuesday's massacre.
Previously, the bloodiest day occurred in February, when 79 prisoners died in simultaneous riots in three prisons in the country. In July, 22 more prisoners lost their lives in the Litoral penitentiary, while in September a penitentiary center was attacked by drones leaving no fatalities.