Cops had to clear about two dozen agitators from a City Council committee hearing on police issues Thursday morning after they repeatedly heckled NYPD Commissioner Bill Bratton and chanted anti-police slogans.

The protesters represented a motley assortment of leftist organizations — and grew especially furious when the commissioner talked about adding more officers to the department.

“Just in case you didn’t know, Broken Windows has got to go,” shouted one man, referring to the policy Bratton backs, under which cops tackle small crimes to help prevent more serious mayhem.

“Community policing is genocide!” shrieked a woman at about 10:30 a.m. during the public safety committee meeting at City Hall.

At first, four individual protesters were ejected by the council’s sergeant-at-arms after they shouted their grievances.

Then a fifth, a woman, refused to leave, at first clinging to her chair and then sitting down cross-legged on the floor.

At that point, about 20 others jumped to their feet and began chanting “Bratton has to be fired!” and the inevitable “No justice, no peace!”

At that point, cops moved in and along with the sergeant-at-arms, forcibly cleared the rabble-rousers — and all other members of the public — from the room.

“I’m not moving!” one of the protesters shouted, but he and about 20 others were eventually cleared away.

Bratton, meanwhile, took the barbs in stride.

“As Jimmy Durante used to say, everybody wants to get into the act,” he cracked, as council members laughed.