NYPD Sgt. Paul Tuozzolo of Long Island was remembered Thursday as a selfless hero who saved the lives of his fellow officers moments before he was killed in a shootout in the Bronx.

Mourners at Tuozzolo’s funeral were told the sergeant’s final words were a warning about the suspect they were closing in on: “Gun! Gun! Gun!”

Thousands of police officers formed a sea of blue outside St. Rose of Lima Church in Massapequa. Utility poles along Merrick Road, the route of the hearse, were festooned with blue ribbons and handwritten signs offering prayers and support.

Then came an emotional two-hour funeral Mass in the packed church — with top police officials, New York Mayor Bill de Blasio and Cardinal Timothy Dolan in attendance.

Tuozzolo, 41, of Greenlawn, who was married with two young sons, died after being shot in the head last Friday by the fleeing burglary suspect, Manuel Rosales, 35, of Brentwood. Rosales died in a hail of police gunfire.

Edward Mullins, president of the Sergeants’ Benevolent Assocation, told mourners that Sgt. Emmanuel Kwo, who was shot in the leg in the shootout, asked him to share a recent conversation.

“Sgt. Kwo said to me, ‘Paul saved my life, Ed. . . . Paul’s final words were a warning to me and my partner. He yelled to us, ‘Gun! Gun! Gun!’ ”

Mullins said of Tuozzolo: “Paul was a warrior. His actions last Friday can only be described as those of a hero.”

“We were blessed to have him among us, and the NYPD was blessed to call him our own,” NYPD Commissioner James O’Neill said in his eulogy, pausing as his voice quaked with emotion. “ . . . Paul protected all New Yorkers, and he died while keeping people safe.”

At one point, O’Neill, attending his first line-of-duty funeral since becoming the top cop, addressed Tuozzolo’s wife, Lisa, and their sons, Austin, 4, and Joseph, 3.

“We can never thank you adequately for what he gave our department and our city,” he told them.

O’Neill described Tuozzolo as a cop with a “level demeanor” — a front-line supervisor “with a dry sense of humor, who never got upset.”

Tuozzolo joined the NYPD in 1997, because, the commissioner said, “he wanted to lead a life of significance. And he did.”

O’Neill announced that Tuozzolo would be posthumously promoted to sergeant special-assignment, drawing rousing applause.

Tuozzolo, who grew up in Bayville, was a 19-year veteran of the NYPD, a department that has grappled with the loss of five officers — all killed in the line of duty — since 2014. In attendance Thursday were the parents of Det. Wenjian Liu, fatally shot in December 2014, and the father of Det. Brian Moore, shot and killed in Queens in May 2015.

Fellow officers from the 43rd Precinct in the Bronx filled the pews of the church’s balcony. One buried his face in his hands, covering tears. Others clasped their white-gloved hands in prayer.

Sgt. Paul Tuozzolo, a 41-year-old NYPD officer from Greenlawn, was...

Sgt. Paul Tuozzolo, a 41-year-old NYPD officer from Greenlawn, was fatally injured during a shootout in the Van Nest section of the Bronx on Nov. 4, 2016, in which another NYPD officer was wounded, officials said. Credit: NYPD

De Blasio, paused and bowed his head in front of Tuozzolo’s coffin, before delivering his remarks.

That afternoon in the Bronx, Tuozzolo could have sent his fellow officers forward, but he took the lead, de Blasio said. “That is the measure of the man, and he gave his life protecting his fellow officers, protecting all of us.”

De Blasio added: “There is one fewer dangerous person on the streets today because Sgt. Tuozzolo stepped forward to fight danger, to fight crime, to fight the evil around us.”

Police officials said President-elect Donald Trump had called the widow to offer his condolences.

Outside the church, thousands of NYPD officers gathered in tribute, joined by cops from Canada, Chicago and other departments across the metropolitan area.

Police recruits from the NYPD and Nassau and Suffolk police departments lined the funeral procession route, where Putnam County, New York State, and Park and MTA police were also represented.

Suffolk Police Commissioner Timothy Sini and acting Nassau Police Commissioner Thomas Krumpter stood with their officers.

All saluted as pallbearers carried the sergeant’s burgundy coffin draped with the green, white and blue NYPD flag.

A sobbing Lisa Tuozzolo followed, held up by two men — one on each side.

Burial was at St. Charles/Resurrection Cemeteries in East Farmingdale.

From house decorations and candy makers to restaurant and theater offerings, NewsdayTV's Elisa DiStefano checks out how Long Islanders are celebrating this holiday season. Credit: Newday

Holiday celebrations around LI From house decorations and candy makers to restaurant and theater offerings, NewsdayTV's Elisa DiStefano checks out how Long Islanders are celebrating this holiday season.

From house decorations and candy makers to restaurant and theater offerings, NewsdayTV's Elisa DiStefano checks out how Long Islanders are celebrating this holiday season. Credit: Newday

Holiday celebrations around LI From house decorations and candy makers to restaurant and theater offerings, NewsdayTV's Elisa DiStefano checks out how Long Islanders are celebrating this holiday season.

SUBSCRIBE

Unlimited Digital AccessOnly 25¢for 6 months

ACT NOWSALE ENDS SOON | CANCEL ANYTIME