CHICAGO — The Chicago Police Department recently overstepped prosecutors to charge a man accused of a brutal deadly attack with a hammer — after he claimed self-defense.

According to police, Gregory Stamps, 31, met the victim David Castile, 42, Sunday night at Club Escape — a bar located in the 1500 block of East 75th Street. Castile gave Stamps a ride home and went up to his apartment.

Later that night, a neighbor saw blood in the hallway and called police, according to court records. Once on scene, officers found Stamps covered in blood. He initially told officers he fell down the stairs and landed in a pool of blood. He then later admitted he hit Castile numerous times with a hammer while in his bedroom — claiming self-defense.

Stamps claimed Castile tried to rape him and then admitted to dragging Castile down three flights of stairs. Outside, he was left with no clothes on after Stamps allegedly threw all his belongings in the dumpster.

Castile was still alive when officers arrived, but later died at the hospital. Detectives said they found the hammer in Stamps’ bedroom and Castile’s wallet in Stamps’ pocket.

The Cook County State’s Attorney’s Office did not approve a murder charge. On Tuesday, CPD District 1 Commander Charles Brown overrode the decision — feeling there was overwhelming evidence in the case.

The move is extremely rare, according to legal experts.

“Generally what happens is the police investigate, they take it to the State’s Attorney’s Felony Review Unit, decides whether or not it should be filed. I can’t remember the last case where the felony review assistant has been overruled by the Chicago Police Department,” Kent College of Law professor Richard Kling said.

Stamps was recently arrested on March 1 after allegedly punching a security guard at a North Side bar. He was released on an I-bond, according to court records.

He was also on parole for a 2013 attempted murder. It was a domestic stabbing where records show he also claimed self-defense. Stamps was sentenced to six years. Between 2009 and 2012, he was charged with retail theft, prostitution and domestic battery.