(Reuters) - A massive fire swept through an overcrowded prison in Honduras and killed more than 350 inmates, including many trapped inside their cells, officials said on Wednesday.

The attorney general's office said 357 people died in the blaze that began late on Tuesday night at the prison in Comayagua, about 75 kilometers (45 miles) north of the capital Tegucigalpa.

Lucy Marder, head of forensic services in Comayagua, said police reported that one of the dead was a woman who stayed overnight and the rest were prisoners, but she said some of those presumed dead could have escaped. Local media reported that the Comayagua fire department chief also died in the blaze.

It was one of the worst prison fires ever in Latin America, and local radio reports said many of the inmates were burned to death inside their cells.

Honduras has the highest murder rate in the world, according to the United Nations, and there are frequent riots and clashes between members of rival street gangs in its overcrowded prisons.

The gangs, known as 'maras', started in the United States and then spread down into Central America, with members covered in distinctive tattoos and involved in drug trafficking, armed robbery and protection rackets.

Soldiers, police and anxious relatives surrounded the Comayagua prison on Wednesday morning and television images showed weeping relatives pressed against a chain link fence as they waited for news. The prison housed more than 800 inmates -- well above its capacity.

This is desperate, they won't tell us anything and I think my husband is dead, a crying Gregoria Zelaya told Canal 5 TV as she stood outside the prison.

Local firemen said they were prevented from entering the prison due to gunshots. But Daniel Orellana, head of the prison system, said there was no riot.

We have two hypotheses, one is that a prisoner set fire to a mattress and the other one is that there was a short circuit in the electrical system, he said.

Across Honduras, prisons are filled to double their capacity. More than 100 prisoners were killed in a fire in the textile manufacturing town of San Pedro Sula several years ago.

Honduras clocked more than 80 homicides per 100,000 people in 2009, a rate 16 times that of the United States, according to a United Nations report last year.

The country is also a major drug trafficking transit point for South American cocaine moving north to consumers in the United States and authorities say there is increasing presence of violent Mexican drug cartels in the country.

A political crisis ripped through Honduras in mid-2009 when a widely-condemned coup toppled the democratically elected president but the country has been trying to heal divisions since the election of President Porfirio Lobo later that year.

(Additional reporting by Reuters Staff Writers Cyntia Barrera and Mica Rosenberg in Mexico.)

--