A fire in a dormitory at a Mexican immigration detention centre near the US border has left more than three dozen migrants dead.

Hours after the fire broke out late on Monday, rows of bodies were laid out under silver sheets outside the facility in Ciudad Juarez, across from El Paso, Texas.

A total of 39 people died and 29 were injured and are in “delicate-serious” condition, according to the National Immigration Institute.

There were 68 men from Central and South America held in the facility at the time of the fire, the agency said.

Mexico Migrant Deaths
Dozens of migrants were killed and injured (AP)

It was the deadliest incident inside a Mexican immigration facility in recent memory.

Authorities are investigating the cause of the fire and the governmental National Human Rights Commission has been called in to help the migrants.

The agency said that it “energetically rejects the actions that led to this tragedy” without any further explanation of what those actions might have been.

The country’s immigration detention centres have seen protests and riots from time to time.

Mostly Venezuelan migrants rioted inside an immigration centre in Tijuana in October that had to be controlled by police and National Guard troops.

In November, dozens of migrants rioted in Mexico’s largest detention centre in the southern city of Tapachula near the border with Guatemala. No one died in either incident.

Ciudad Juarez is a major crossing point for migrants entering the United States. Its shelters are full of people waiting for opportunities to cross or who have requested asylum in the US and are waiting for a decision.

In recent years, as Mexico has stepped up efforts to stem the flow of migration to the US border under pressure from the American government, its National Immigration Institute has struggled with overcrowding in its facilities.

The high level of frustration among migrants stuck in Ciudad Juarez was on display earlier this month when hundreds of mostly Venezuelan migrants acting on false rumours that the United States would allow them to enter the country tried to force their way across one of the international bridges to El Paso. US authorities blocked their attempts.