Mahershala Ali won’t do sex scenes onscreen, and explained why during an appearance with Common on his “Mind Power Mixtape” podcast.

As he explained, Ali feels simulating sex for a movie or TV show is contrary to the to his Islamic faith.

This nearly became an issue when he was cast in “The Curious Case of Benjamin Button”, which required him to appear in a sex scene with co-star Taraji P. Henson.

RELATED: NSFW: Mahershala Ali Joins Ramy Youssef In Sneak Peek At Season Two Of ‘Ramy’

“So my old agent called me and said, ‘Mahershala, you got the part.’ And I said, ‘There’s just one thing… There is that one sex scene where they kiss… If there’s a sex scene, I can’t do it.’”

He added, “I don’t do simulated sex.”

However, director David Fincher was able to shoot the scene in such a way to serve the needs of the film while adhering to Ali’s Muslim beliefs.

RELATED: Chris Pratt Reacts To ‘Blade’ Movie Starring Mahershala Ali: ‘Oh My God, I’ve Got To See That’

“Taraji and I begin to kiss, and we fall out of the frame,” he said. “It wasn’t clear if [Fincher] was trying to have like some bumping and grinding… which I doubt he was. But for me even… at that time, 15 years ago, I was still like, ‘Okay, I can only go up to this point,’ just because of — just trying to hold a space of respect for my religion.”