The factory was scheduled to be operational by March 2025, and was set to be BYD’s first EV plant outside of Asia.
The workers, hired by Jinjiang Construction Brazil, lived in four facilities in Camaçari city.
At one such facility, workers were made to sleep on beds without mattresses, according to prosecutors.
Each bathroom was also shared among 31 workers, forcing them to get up extremely early in order to be ready for work.
“The conditions found in the lodgings revealed an alarming picture of precariousness and degradation,” the MPT said.
“Slavery-like conditions”, as defined by Brazilian law, include debt bondage and work that violates human dignity.
The MPT added that the situation also constitutes “forced labour”, as many workers had their wages withheld and faced excessive costs for terminating their contracts.
BYD said affected workers had been moved to hotels.
It added that it had conducted a “detailed review” of the working and living conditions for subcontracted employees, and asked on “several occasions” for the construction firm to make improvements.
BYD, short for Build Your Dreams, is one of the world’s largest EV makers.
It sold more electric vehicles than Elon Musk’s Tesla in the last three months of 2023, as the two battled for top spot in the sector.
The company has also been expanding its foothold in Brazil, which is its largest overseas market by a wide margin.
It first opened a factory in São Paulo in 2015, producing chassis for electric buses.
Last year, it announced that it would invest 3 billion reais ($484.2m) in Brazil to build an EV manufacturing plant.
EV sales in China have been boosted by government subsidies. which encourage consumers to trade their petrol-powered cars for EVs or hybrids.
But there is a growing backlash abroad against what some see as the Chinese government’s unfair support for domestic car makers.
Major markets like the US and EU have placed tariffs on EVs from China, with more tariffs expected during the incoming administration of US president-elect Donald Trump.