A bigot wanted for a hate crime against a transgender woman has surrendered to police to face charges for the attack, authorities said Wednesday.

David Gonzalez, 34, turned himself in around 9:45 p.m. Tuesday — weeks after he allegedly made hateful comments to a 29-year-old transgender woman before discharging pepper spray in her face, cops said.

Gonzalez is accused of approaching his victim in the area of Roosevelt Avenue and 82nd Street in Jackson Heights around 4:15 a.m. June 29 and making unspecified transphobic statements before spraying her in the eyes, police said at the time.

Earlier that morning, a 43-year-old woman was the victim of a similar attack at the same intersection — in which 24-year-old Paola Custodio allegedly made anti-transgender comments and anti-gay slurs before spraying the victim in the chest with an unknown liquid.

Police said the two incidents were connected, and Custodio was charged with hate crime assault and harassment as a hate crime.

Gonzalez, who lives blocks from where the attack happened, was charged Tuesday with two counts each of felony assault as a hate crime, aggravated harassment as a hate crime and aggravated harassment, according to authorities.

He boasts 28 prior arrests dating back to 2002, including multiple arrests for assault, robbery, grand larceny and criminal possession of a weapon, police sources said.