A man wanted for raping a woman while she slept in her Bushwick apartment turned himself in to police late Wednesday, an NYPD spokeswoman said Thursday.

Jason Lasry, 38, who lives about a 20-minute walk from the victim's building, entered the 24-year-old woman's apartment near Halsey Street and Central Avenue at about 10:30 p.m. Saturday, police said. He then got into the woman’s bed while she was sleeping and raped her, cops said.

The woman was able to push off Lasry, who then fled, according to police. She was taken to Woodhull Medical Center where she was treated and released.

Police said the door to the woman's apartment was unlocked. Investigators believe Lasry tried several doors in the building before he found one that was unlocked.

Lasry turned himself over to police at the 77th Precinct around 9 p.m. Wednesday, the spokeswoman said. The NYPD had released surveillance footage of him on Tuesday night.

He has been charged with rape, according to police.