A New York judge expressed horror at letters written in support of a retired police officer who admitted to repeatedly raping a teenage girl — but he managed to avoid prison anyway.

Adam Mesiti pleaded guilty to third-degree rape of a 16-year-old, but the letters showed his friends and family still believed he was innocent and had already suffered enough, reported The Daily News.

ADVERTISEMENT

One letter said Mesiti’s family had been “unjustly disgraced,” and a church deacon insisted “the proof can often be so inconclusive,” and the sentencing judge blasted the former Brockport police officer.

“This tone permeates these letters,” said Judge Sara Sheldon. “These people that love you so much don’t believe you did this. The vast majority don’t believe you did it, and I think it’s because you told them you didn’t.”

A friend complained that the 46-year-old Mesiti, who met the girl when he was working as a school security officer, had his life and career “ruined by accusations and innuendo” because he had agreed to work with students.

The officer took in the girl for a time after meeting her at the school, and their relationship then turned sexual.

Mesiti had pleaded guilty May 22 before another judge who has since retired, and the former officer agreed to register as a sex offender and face a sentence no greater than six months of incarceration and 10 years of probation, the newspaper reported.

ADVERTISEMENT

“I’m not comfortable with this,” said Sheldon, who faulted the former officer and his supporters for calling the victim’s statements into question.

“Please be comfortable — I did it,” Mesiti told the judge. “There’s no sense in dragging my family, and this young lady, through this.”

Sheldon nearly sent the case back to “square one” after Mesiti’s attorney suggested prosecutors had coerced the retired officer’s guilty plea by threatening his family, but the defense attorney apologized and claimed he misspoke.

ADVERTISEMENT

Mesiti had been charged with 10 counts of third-degree rape, 20 counts of criminal sexual conduct and 30 counts of sexual misconduct.

The judge sentenced Mesiti to 10 years of probation, and he must register as a sex offender.

ADVERTISEMENT

He faced a maximum of four years in prison if convicted on all counts.