The show of disrespect came outside the funeral home where Officer Wenjian Liu was remembered as an incarnation of the American dream: a man who had immigrated at age 12 and devoted himself to helping others in his adopted country. The gesture, among officers watching the mayor's speech on a screen, added to tensions between the mayor and rank-and-file police even as he sought to quiet them.
"As we start a new year, a year we're entering with hearts that are doubly heavy" from the loss of Officer Liu and his partner, Officer Rafael Ramos, de Blasio said. "Let us rededicate ourselves to those great New York traditions of mutual understanding and living in harmony. Let us move forward by strengthening the bonds that unite us, and let us work together to attain peace."
Police convened from around the country to mourn Liu, who was killed Dec. 20. Officer Lucas Grant of the Richmond County Sheriff's Office in Augusta, Georgia, said he came to Liu's funeral with about six other officers from neighboring departments "to support our family."
"When one of us loses our lives, we have to come together," Grant said.
As Liu's family arrived for his funeral, Police Commissioner William Bratton tweeted: "We will never forget his sacrifice."
A day earlier, mourners lined up for blocks on a cold, rainy day for Liu's wake.
"This is a really tragic story," Gov. Andrew Cuomo told reporters following the wake, held just two days after the death of his own father, former Gov. Mario Cuomo.
"This is really pointless. It had nothing to do with them," he said of Liu and Ramos. "They did nothing wrong. ... It was pure and random hatred."
The shooter, Ismaaiyl Brinsley, killed himself shortly after the brazen daytime ambush on a Brooklyn street.
Investigators say Brinsley was an emotionally disturbed loner who had made references online to the killings this summer of unarmed black men at the hands of white police officers, vowing to put "wings on pigs."
The deaths strained an already tense relationship between city police unions and de Blasio, who union leaders have said contributed to an environment that allowed the killings by supporting protests following the deaths of Eric Garner on Staten Island and Michael Brown in Ferguson, Missouri.
The head of the rank-and-file police union, which is negotiating a contract with the city, turned his back on the mayor at a hospital the day of the killings. The act was imitated by hundreds of officers standing last week outside Ramos' funeral who turned their backs toward a giant TV screen as de Blasio's remarks were being broadcast.
Many people, including Cardinal Timothy Dolan, have since pressed all parties to tone down the rhetoric. And this weekend, Bratton sent a memo to all commands urging respect, declaring "a hero's funeral is about grieving, not grievance." Officers who turned their backs on de Blasio on Sunday spun back around when Bratton took the podium to speak after the mayor.
On Saturday, officers standing outside the Brooklyn funeral home where Liu was displayed, dressed in full uniform in an open casket, saluted as the mayor and commissioner entered. On Sunday, the mayor got a respectful reception among police officials inside the funeral home.
But some ill will was visible ahead of de Blasio's scheduled remarks at Liu's funeral. Retired NYPD officer John Mangan stood across the street from the funeral home with a sign that read: "God Bless the NYPD. Dump de Blasio." And Patrick Yoes, a national secretary with the 328,000-member Fraternal Order of Police, said he applauded New York police union leader Patrick Lynch's stance toward the mayor, including Lynch's declaration that de Blasio had "blood on his hands" after the shootings.
"Across this country, we seem to be under attack in the law enforcement profession, and the message to take away from this is: We are public servants. We are not public enemies," Yoes said.
But George Breedy, a lieutenant with the St. Charles Parish Sheriff's Department in Louisiana, said he had no plans to protest de Blasio, calling the rift between officers and the mayor a "local issue."
"We're here to pay respect to the officers," Breedy said.
Liu's funeral arrangements were delayed so relatives from China could travel to New York. He is to be buried at Cypress Hills Cemetery.
On Saturday, a small vigil was established in Chinatown and community members gathered, burning pieces of paper in honor of Liu in keeping with Chinese tradition.
Associated Press writer Jennifer Peltz contributed to this report.