Twenty-four others sustained burns in the blaze in the town of Al Obur, in the city of Qaliubia north of Cairo, the ministry said.
The fire was caused by an explosion of gas butane cylinders in the factory, which manufactures office furniture, security sources said.
Most of the casualties resulted from a stampede among the workers after part of the four-floor factory collapsed because of the fire, they added.
Hot weather fanned the flames and helped them spread to other parts of the site.
Firefighters battled the blaze for hours and eventually got it under control.
Initial investigations showed that the factory had not obtained a safety permit from authorities before it went into operation, the sources said.
The factory’s two owners were arrested.
Lack of safety standards have been blamed for a series of fatal accidents in Egypt in recent years.