A Bronx charter school dean was arrested and charged with rape on Tuesday — for allegedly having sex with a 15-year-old boy she was mentoring, police said.

Grace Trinidad, 34, a dean of discipline at the New Visions Advanced Math and Science High School, invited the student back to her Tinton Avenue home in August to watch movies — but things got hot and heavy and the pair had sex, according to police.

In August, the unidentified victim, whom Trinidad was mentoring at the Spuyten Duyvil school, went to her house and while the pair were watching a movie, they began to kiss and had sexual intercourse, cops said.

The boy and a classmate told the Spuyten Duyvil school’s principal, Robert Hiller, about the incident, and Hiller immediately notified police, according to authorities.

Police from the 40th Precinct questioned Trinidad at her home Tuesday before charging her with rape in the third degree, criminal sex act and endangering the welfare of a child, officials said.

She was expected to be arraigned at Bronx criminal court later Tuesday.

According to her Facebook, Trinidad has two daughters and began working at New Visions — which is housed in the old John F. Kennedy High School — in July 2017.

New Visions did not immediately respond to a request for comment.