The New York City Council moved to end qualified immunity for police officers Thursday, making it the first big city in the nation to do so. 

The measure passed as part of a broader overhaul of police practices. 

The legal doctrine has for decades protected officers from lawsuits alleging misconduct against those they’re arresting, unless the officer had violated a clearly established constitutional right. 

Qualified immunity first came under scrutiny during the racial injustice and police brutality protests that roiled the nation in the light of George Floyd’s death. 

The city council said in a statement the bill would protect New Yorkers against unreasonable search and seizures and against excessive force, in addition to banning qualified immunity. The Big Apple joins two states, Colorado and Connecticut, in curbing the immunity defense. 

GEORGE FLOYD: WHAT TO KNOW 

The bill now goes to the desk of Mayor Bill de Blasio, who is expected to sign it. 

At the same time, city lawmakers approved de Blasio’s plan to spend $72 million to improve police practices and accountability. This came after the city moved to divert $1 billion from the police budget last summer. 

Another provision gives the Civilian Complaint Review Board, which investigates police misconduct, resources to investigate racial bias in policing, and it requires police to collect data on traffic stops, including the race of people apprehended. 

Another resolution the council passed requires newly hired cops to live in New York City limits. 

JURY SET FOR FORMER POLICE OFFICER'S TRIAL IN FLOYD DEATH; BEGINS MARCH 29

New York City Council Speaker Corey Johnson said qualified immunity was "rooted in our nation's history of systemic racism" and "should never have been allowed. 

Opponents of the bill said it might discourage some from getting into law enforcement. "Ending qualified immunity will prevent the best young men and women in our city from joining the police force," Councilman Robert F. Holden said as he voted no, according to the New York Times. 

CLICK HERE FOR THE FOX NEWS APP

"New Yorkers are getting shot, and police officers are on the streets day and night, trying to stop the bloodshed," Patrick Lynch, president of the Police Benevolent Association, said in a statement, adding that the new bill would "chill the operations of law enforcement."