Mayor Eric Adams told reporters that 19 people had been confirmed dead and 63 had been wounded, including several that were in a “critical condition.”
“This is going to be one of the worst fires in our history,” he said.
“Join me in praying for those we lost, especially the 9 innocent young lives that were cut short,” he added in a later tweet.
At least 200 fire-fighters responded to the blaze, which broke out just before 11:00 am (1600 GMT) on the second and third floors of a 19-story building in The Bronx.
The mainly working class borough is home to a large number of immigrants and Adams said “many” of the building’s residents had been Muslims who moved to New York from Gambia.
Photographs and video posted on social media showed flames and thick black smoke billowing out of a third-story window of the brick building at East 181st Street as firefighters operated on a nearby ladder.
“It was chaos,” George King, who lives directly adjacent the building told AFP.
“I’ve been here 15 years and it’s the first time I’ve seen something like this.
“I saw the smoke, a lot of people were panicking. You could see that no one wanted to jump from the building. People were waving from the windows,” he added.
The injured were taken to five hospitals; many suffered from cardiac and respiratory arrest and severe smoke inhalation, officials said.
“The marshals have determined through physical evidence and through firsthand accounts by the residents that this fire started in a bedroom in a portable electric heater,” New York City Fire Department Commissioner Daniel Nigro told reporters.
He said that flames quickly engulfed much of the structure and that the smoke was so dense as to be “unprecedented.”
Nigro added that “very heavy” fire and smoke “extended the entire height of the building.”
“Members found victims on every floor, in stairwells,” he said.
“The last time we had a loss of life that may be this horrific was a fire which was over 30 years ago, also here in the Bronx,” Nigro added.
He explained that the fire originated in a duplex apartment on the second and third floors of the building.
The door to the apartment had been left open, allowing the fire and smoke to spread, he said.
“If you close the door the smoke and fire spread is contained within that apartment instead of spreading up the stairs,” Nigro told reporters.
Buildings like this one don’t have fire escapes, he added.
Rodriguez said the smoke was so thick when she went down that “we couldn’t see.”
“They took my daughter away from me and I got panicked. Once I was walking the stairs, I saw a body on the floor that they tried to rescue. Also a dog, it was dead. And it was really devastating,” she said.
Adams, who only took office on 1 January, said the fire was “truly a tragedy,” adding that many residents had been displaced.
“This is really a horrific day for us,” he said.
Nigro said the fire was the worst since a blaze at Happy Land nightclub in 1990 in the Bronx, which killed 87 people and had been caused by arson.
In December 2017, 13 people were killed in a blaze in an apartment building in the Bronx in New York City’s deadliest fire in 25 years.
It had been started by a three-year-old boy playing with a gas stove.
Sunday’s inferno comes just four days after a fire in Philadelphia killed 12 people, including eight children, in a three-story public housing building.