A police helicopter crashed near one of Rio de Janeiro's impoverished favela neighborhoods on Saturday, killing four officers after a day of intense gunfire in the area, Brazilian police sources told AFP.

"We do not yet have information on the causes, an investigation will be opened," a police spokesman said, confirming that security forces had carried out operations earlier in the day in the Cidade de Deus favela near the site of the crash.

Video shot by witnesses and broadcast by Brazilian media showed the helicopter spinning out of control as it fell from the gray, late-afternoon sky.

The crash followed a tense day of clashes with officers in the densely populated area, causing the flow on one of the city's major highways to be cut off.

In a separate clip published by Brazilian news site UOL, the rumble of gunfire can be heard coming from the streets in the area.

Clashes occurred in the morning and again in the afternoon when drug traffickers blocked a street and set garbage and tires on fire, sources from the Police Pacification Unit (UPP), which was set up to restore order in Rio's crime-ridden slums, told the newspaper Folha de Sao Paulo.

Rio, which is home to 6.5 million people and drastic social inequality, faces high levels of crime fueled by bands of heavily armed drug traffickers.

Since 2008, security forces have occupied several favelas that were in the hands of drug traffickers for 30 years and have also deployed the UPP in 264 impoverished, crime-hit neighborhoods housing more than a million people.

Although the areas are patrolled by around 10,000 officers, drug trafficking groups are pushing to regain control of some of the favelas.