The "Christ is Love" centre for drug and alcohol addicts was unlicensed and overcrowded and its residents were apparently kept inside "like prisoners," Health Minister Alberto Tejada told The Associated Press.
Authorities said 26 people died at the scene, and prosecutors spokesman Raul Sanchez said last night that one of six men hospitalised in critical condition died later. Peru's fire chief, Antonio Zavala, said most of the victims died of asphyxiation.
All the victims appeared to be male. The local police chief, Clever Zegarra, said the cause of the 9 am fire was under investigation.
"There has been talk of the burning of an object, of a mattress, but also of a fight that resulted in a fire. All of this is speculation," he told the AP.
"I've been here at the scene from morning to evening but for the moment the exact cause of the fire is not known."
One resident of the centre on a narrow dead-end street in Lima's teeming San Juan de Lurigancho district said he was eating breakfast on the second floor of the centre when he saw flames coming from the first floor, where the blaze apparently began. Gianfranco Huerta told local RPP news radio station that he leaped from a window to safety.
"The doors were locked; there was no way to get out," he told the station. AP journalists at scene said all the windows of the building they were able to see were barred. Journalists were not allowed inside as police cordoned off the block. By early afternoon, all the dead had been removed from the centre.