US Senator Zellnor Myrie pepper-sprayed at George Floyd protest

A black US senator who was pepper-sprayed by police officers during protests in New York City says African Americans are being wrongly targeted by police.

Senator Zellnor Myrie was wearing a neon green T-shirt with his name and title visible while attending a "peaceful" demonstration in Brooklyn on Friday. When police on bikes surrounded the crowd, he tried to act as a human shield against protesters and the officers while being shoved and yelled at. He was subsequently pepper-sprayed and put in handcuffs.

Myrie later shared photos on Twitter of him in visible pain after being sprayed, with the caption "pain".

He told Channel Nine it's likely he would've been arrested if he wasn't a politician.

"It goes to the heart of why we are protesting. Many of us have been targeted simply because we are black. The numbers bear that out. The deaths bear that out. The lack of consequences bear that out as well."

Once police realised he was a senator, he was let go.

He says he was trying to help officers keep the peace and manage the crowd before he was pepper-sprayed.

"The irony, of course, is that the first time both of those things happen to me is as a state senator protesting police brutality."

He added that police officers need to show restraint since they're the only people that can kill while being protected by the law.

"That is an immense and powerful responsibility and we hope that the restraint will also be immense and powerful as well."

Protests over the death of US man George Floyd continued for the ninth night on Wednesday (local time) in America.

Floyd died after police officer Derek Chauvin knelt on his neck for nearly nine minutes while he was under arrest.

Chauvin was fired as an officer and has since been charged with second-degree murder - which can carry a sentence of up to 40 years. The three other officers involved in the incident - Thomas Lane, J. Alexander Kueng and Tou Thao - are charged with aiding and abetting second-degree murder.