A firefighter was killed late Thursday while battling a blaze that broke out at a Harlem building where film crews were shooting a new Edward Norton and Bruce Willis movie, police and fire sources said.

Michael Davidson of Harlem’s Engine Company 69 — a father of four — was briefly reported missing after a mayday call was made from the fiery building, officials said.

Davidson was soon found and rushed to Harlem Hospital, where he was pronounced dead, authorities said.

Two other firefighters were also listed in serious condition with burns early Friday at Weill Cornell Medical Center, though their wounds were not considered life-threatening, sources said.

Flames broke out in the basement of 773 St. Nicholas Ave. at about 11 p.m. No one was in the basement at the time, but film work was being done just outside on the set of “Motherless Brooklyn,” a movie set to be released next year, witnesses and officials said.

“They went down the stairs to fight the fire with Davidson as nozzleman,” FDNY Commissioner Daniel Nigro told reporters at Harlem Hospital early Friday.

“The fire was too heavy. They were forced to retreat and as they backed out, he (Davidson) got separated from the rest of the unit. He was found unconscious on the floor and despite the best efforts of the FDNY and EMTs, they were unable to revive him.”

Nigro added: “Our entire city mourns his loss.”

The 37-year-old, 15-year department veteran leaves behind his wife, Eileen, and four daughters.

He also has a brother, Eric, who is a city fireman in Engine 88. Their dad, Robert, is retired FDNY, also from Engine 69.

Mayor Bill de Blasio’s spokesman Eric Phillips said he was at the hospital when Davidson’s mother arrived.

He tweeted: “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.”

Davidson had been cited for bravery four times in his career and is the 1,150th New York firefighter to die in the line of duty in the history of the department, according to the FDNY.

Three civilians suffered non-life-threatening injuries in the blaze, fire officials said.

The film location is where the old St. Nick’s Jazz Pub once operated.

Norton stars in the flick and is listed as director and writer. Willis, Willem Dafoe and Alec Baldwin are also in the cast.

The film crew was setting up to shoot outside the five-story building when Norton spotted smoke coming from the basement and alerted a nearby cop, law enforcement sources said.

Neighborhood resident Daquan Evans, 28, said he spotted a visibly shaken Norton at the scene.

“That actor Ed Norton walked right by. He looked pretty upset,” Evans said. “This is crazy, this fire. You think a movie comes up here and it is good for the neighborhood. Not a fire … Damn.”

The five-alarm blaze, which was battled by about 200 firefighters, was declared under control at about 2:30 a.m. Friday, officials said. It was not known how the blaze started, though fire officials are investigating.

Additional reporting by David K. Li