At least 38 inmates have died in Apodaca prison riot in northern Mexico.
Security officials said the inmates had either forced or bribed a number of guards to open the doors between two separate wings of the jail.
A fight broke out between the prisoners, in which the killings occurred.
Deadly prison fights between rival gangs are not uncommon in Mexico: last month 31 inmates were killed in similar circumstances in Tamaulipas state.
Nuevo Leon state security spokesman Jorge Domene said inmates at the Apodaca prison had also set fire to mattresses and other flammable objects.
“Until now, we have counted 38 dead,” he said.
Jorge Domene said investigations were under way to establish the causes behind the fight, but that so far the evidence pointed towards a confrontation between rival gangs.
He said the security forces were now in control of the situation.
Relatives of the prisoners have gathered outside the prison, north of the city of Monterrey, to find out news about who has been killed and injured.
Jorge Domene asked them to be patient.
“We have more than 3,000 inmates in this jail and we have to account for all of them first,” he said.
Mexican jails are notorious for overcrowding, corruption and rioting.
In January, 31 inmates were killed at a prison in Altamira, in Tamaulipas state, when rival gangs confronted each other with homemade weapons and knives.