The fire broke out in the basement of the building on St. Nicholas Avenue just before 11 p.m.
Flames poured out the windows as members of Engine 69 moved into the five-story building, dumping water on the blaze to get it under control.
Firefighter Michael Davidson, who was assigned to the nozzle with the responsibility of operating a hoseline to suppress the fire, became separated from his fellow firefighters as conditions rapidly were deteriorating.
Officials said after a desperate search to locate Davidson, he was found unconscious. He was transported to Harlem Hospital, where he died.
FDNY Commissioner Dan Nigro hailed the 15-year veteran as a hero.
"Firefighter Davidson bravely battled many fires and responded to countless calls for help from New Yorkers throughout his 15 years of dedicated service," he said. "Our department and our entire city mourn this tragic loss of a very brave firefighter."
"It's an awful night," Eric Philips, a spokesman for Mayor Bill de Blasio, said in a tweet. "You haven't heard a scream until you've heard the scream of a mother who's seen her son give his life to protect us."
Mayor de Blasio was in Florida for a personal trip, but he was returning to New York City to grieve with Davidson's family and colleagues.
Two more firefighters were seriously injured with burns, while three civilians suffered minor injuries. The firefighters were treated at a hospital and released.
While the exact cause of the fire remains unknown, investigators believe it could have been accidental.
Investigators said they learned the building's landlord had been doing work on either the electrical system or boiler.
Because the building was so badly damaged, it took hours to shore up the structure before investigators could go inside.
The building was home to the former St. Nick's Jazz Pub, a venerable bar that was closed in 2011. It was being used to film "Motherless in Brooklyn."
Norton, who also wrote the screenplay, was spotted at the scene of the fire. They were shooting on the first floor when the fire broke out in the basement.
A statement was issued on behalf of the movie's producers:
Our deepest condolences to the family of Michael R. Davidson. A fire broke out tonight in the building where we were shooting our film. Our production was towards the end of our working day and had dozens of people working on site, when our crew noticed that smoke was coming into our set and into other parts of the building from below us. As soon as we noticed smoke coming up into our set, our crew immediately alerted the fire department and began alerting residents of the building even as we evacuated our cast and crew. To our great sorrow, we now know that a NYC firefighter lost his life battling the blaze that grew, and our hearts ache in solidarity with his family. New York City firefighters truly are the bravest in the world. We watched firsthand with astonishment as they charged into the smoke to make sure all were safely out and then fought to contain the blaze and prevent it from spreading, putting their lives on the line as they do every day. The FDNY are real-life super-heroes and have our boundless admiration and gratitude.
The movie also stars Bruce Willis, Willem Dafoe and Alec Baldwin.
Neighbors said the movie crew had set up a sign that read "King Rooster Jazz Club" about two weeks ago. Cars from the 1950s era lined the street.