A repeat sex offender was sentenced to 25 years to life Wednesday for the two-decades-old rape and murder of a pregnant Harlem woman after DNA evidence linked him to the cold case.

As part of a plea deal, Melvin Kelly, 58, copped to fatally strangling five-months-pregnant Isabelle Joye on a rooftop on May 18, 1994.

Hours later, a young boy stumbled on the woman’s half-naked body.

Kelly left behind his DNA on two tissues and under her fingernails, but the crime remained unsolved for years until new forensic techniques were used to test the samples and produce a genetic profile.

That profile was then uploaded to the New York State DNA Databank, where it matched Kelly, who had been convicted of a 2004 sexual assault of a man in Greenwich Village. He’s already serving 25 years to life on that case.

Rebecca Rosenberg