Hundreds of people were working at the Blueberry factory when the explosion ripped through the building in Ciudad Juarez, a city bordering the US state of Texas, officials said.
Smoke billowed from the building, located in an industrial park, while a side wall collapsed following the early afternoon blast, an AFP correspondent said.
Terrazas said a boiler had exploded, causing the second-floor ceiling to collapse.
But civil protection chief Fernando Motta Allen said the source and cause of the blast were unclear, though it caused a fire that was now under control.
The explosion took place in the furnace section of the factory and that walls collapsed, but not the ceiling.
Motta said seven of the injured people were in serious condition and another four were in a critical but stable state. He earlier said 10 people were in serious condition due to burns and other injuries.
“It is possible that some people were trapped after the ceiling collapsed due to the explosion,” he said.
Motta said rescuers were checking whether there were any people trapped in the rubble.
Some 900 workers were at the factory at the time of the explosion but it was not immediately clear how many were on the floor where the incident took place, he said.
Some 30 ambulances rushed to the scene of the explosion to take the injured to hospitals. Soldiers wearing dust masks and toting assault rifles were deployed to the site.
Broken pieces of cement from the building were strewn on the street.
Ciudad Juarez, which lies across the border from the US city of El Paso, has been a manufacturing hub for years, though it has become more famous for drug cartel violence more recently.
Terrazas said the sweets manufactured by Blueberry are produced for the export market.