The fire service said the denim recycling plant in the Jamuna Spinning Mill, located at Safipur in Kaliakoir Upazila, caught fire just after 5am on Sunday.
As many as 14 fire-fighting units from Kaliakoir, Dhamrai, Joydevpur and Savar EPZ have rushed to the spot to fight the flames.
Gazipur Fire Service's Deputy Assistant Director Md Akhtaruzzaman said the fire spread from denim recycling unit to the warehouses of weaving and finishing sections of the factory.
The cause of the fire was not yet known. The Gazipur district administration and the fire service have launched separate probes.
The Jamuna Spinning Mill, founded in 2002, is capable of producing 24,000 kg of yarn daily.
According to the company's website, the factory has 1,200 employees.
The factory's Deputy General Manager Alamgir Hossain said that the 13 people on the night shift have all been able to move out to safety.