Mila Kunis has called out sexism in the workplace with a powerful essay detailing what happened to her when she refused to pose semi-naked for a men's magazine to promote a movie.

In a take-down of the Hollywood boys’ club, the "Bad Moms" star called time on the “bulls--t”.

“I’m done tolerating sexism in the workplace,” Kunis wrote in an op-ed for husband Ashton Kutcher’s A Plus website.

“I taught myself that to succeed as a woman in this industry I had to play by the rules of the boy’s club. But the older I got ... the more I realized ... that it’s bulls--t.”

Mila Kunis talks Macaulay Culkin relationship

“And, worse, that I was complicit in allowing it to happen.”

Recounting her own experience in standing up to a producer because she didn’t want to pose semi-nude in a photo, Kunis was told her career would end if she didn’t do what he wanted.

“‘You’ll never work in this town again’ is what a producer threatened when I refused,” Kunis said.

“I was no longer willing to subject myself to a naive compromise that I had previously been willing to ... I was livid, I felt objectified, and for the first time in my career I said ‘no.’”

An angry Kunis had a message for the unidentified film producer: “I will work in this town again,” she said. “But I will not work with you.”

Acknowledging gender bias in the workplace extends way beyond Hollywood, Kunis said: “It’s what we are conditioned to believe — that if we speak up, our livelihoods will be threatened; that standing our ground will lead to our demise.”

'Voice' alum claims Big Machine, manager told her to keep quiet about sexual assault

“We don’t want to be kicked out of the sandbox for being a ‘bitch,’, so we compromise our integrity for the sake of maintaining the status quo and hope that change is coming.”

Kunis details trying to change the rules by starting her own female-run production company, and still striking hurdles, including one sadly memorable moment when a male producer her team was working with tried to use her husband to promote her in a sales pitch.

“In this email chain, this producer chose to email the following: ‘And Mila is a mega star. One of biggest actors in Hollywood and soon to be Ashton’s wife and baby momma!!!’,” Kunis wrote.

“This is the entirety of his email ... he reduced my value to nothing more than my relationship to a successful man and my ability to bear children. It ignored my (and my team’s) significant creative and logistic contributions.”

Kunis and the team withdrew from the project.

“If this is happening to me, it is happening more aggressively to women everywhere,” she said.

Mila Kunis embarrassed by sex talk on 'Ellen'

“I am fortunate that I have reached a place that I can stop compromising and stand my ground, without fearing how I will put food on my table,” the actor wrote.

“I am also fortunate that I have the platform to talk about this experience in the hope of bringing one more voice to the conversation so that women in the workplace feel a little less alone and more able to push back for themselves.”

Kunis is done with compromising, “or being compromised”.

“From this point forward, when I am confronted with one of these comments, subtle or overt, I will address them head on; I will stop in the moment and do my best to educate,” she pledged.

“I cannot guarantee that my objections will be taken to heart, but at least now I am part of creating an environment where there is the opportunity for growth.”

“And if my comments fall on deaf ears, I will choose to walk away.”

This article originally appeared on News.com.au.