A major push by the NYPD against gangs has led to record-setting declines in homicides and shootings this year, but officials said they are wary about a possible upsurge in violence if street crews merge with drug gangs as the city experienced in the 1980s.

So far this year, there have been 161 homicides, compared with 172 in 2015, a decline of 6.4 percent, while shootings have plummeted to 435 from 554 in the prior year, a decline of 21.5 percent, according to NYPD data released Monday. Overall, all serious crimes were practically unchanged from a year earlier.

With gang shootings traditionally accounting for many of the city’s killings, Chief of Detectives Robert Boyce said Monday investigators focused hard on the street crews and carried out 41 major takedowns around the city. The result has been a major decline in violence, he noted.

Gang-motivated homicides so far this year total 11, compared with 29 in 2015, a 62 percent reduction, Boyce said. Meanwhile, gang shootings in 2016 total 84, compared with 165 last year, a drop of 49 percent.

“So we are seeing quite a benefit out of these long-term investigations with these great detectives doing this work,” Boyce said during a midyear crime briefing attended by NYPD Commissioner William Bratton and Mayor Bill de Blasio.

“It is probably the best thing we have done gang wise,” Boyce stressed.

advertisement | advertise on newsday

“The numbers are very, very good,” Bratton said of the data on serious crimes.

Shootings alone are at a level which is the lowest in the CompStat era of record keeping, Deputy Commissioner Dermot Shea said.

But Boyce noted developments in narcotics trafficking, including purer and more powerful heroin from Latin American source countries, were a continuing cause of concern.

“There is major sea change, if you will, in where heroin in coming from. . . . the quality of that heroin has changed dramatically,” Boyce said. “It was 10 percent [purity], now it is up to 60 percent and creating more and more overdoses.”

The purer heroin is also selling in increments for $10, the same price as it was back in the 1970s, thus making a more destructive drug available at a relatively cheaper price, Boyce added.

While street gangs and drug gangs don’t seem to have worked out alliances, Boyce said if they merge activity it could spell problems.

“Right now they are not together,” Boyce said. “We are hoping they don’t come together as they did in the crack-cocaine . . . [era].”

Boyce was referring to the period in the 1980s when the crack scourge contributed to the highest homicides levels in city history which topped off at 2,245 deaths in 1990. This year the city is on track to end the year with about 330 homicides.