Danny Masterson was supported by former co-stars Ashton Kutcher and Mila Kunis in letters sent to the judge ahead of his sentencing hearing Thursday.

Masterson, 47, will serve 30 years to life after being convicted on two counts of forcible rape. He is currently being held at the Los Angeles County Sheriff's Men's Central Jail as he awaits his transfer to a California state prison. The department confirmed to Fox News Digital that the actor is being checked on every 30 minutes.

Kutcher starred alongside Masterson on the sitcom "That ‘70s Show" as Michael Kelso, and wrote about their time on the show in the letter, obtained by Fox News Digital.

"Danny takes his job seriously. He is kind, courteous, and hard working," Kutcher wrote. "He treated everyone from the grips to the teamsters to the actors to the caterers as equals."

DANNY MASTERSON INTERVIEW WITH CONAN O'BRIEN RESURFACES AFTER RAPE SENTENCING: ‘YOU’LL BE CAUGHT'

Mila Kunis, Ashton Kutcher and Danny Masterson attend a premiere

The judge who sentenced Danny Masterson, right, to 30 years to life in prison for his rape conviction received letters of support from Mila Kunis and Ashton Kutcher. (SGranitz/WireImage via Getty Images)

"As a role model, Danny has consistently been an excellent one. I attribute not falling into the Hollywood life of drugs directly to Danny. Any time that we were to meet someone or interact with someone who was on drugs, or did drugs, he made it clear that that wouldn't be a good person to be friends with. And for me, that was an implication that if I were to do drugs, he wouldn't want to be friends with me, which is something I never would want to risk or jeopardize. I am grateful to him for that positive peer pressure," he wrote.

Masterson was accused of drugging his three victims and then raping them during his retrial. Deputy District Attorney Reinhold Mueller said Masterson put substances into drinks that he gave to a longtime girlfriend and two women he knew through friend circles around the Church of Scientology, all of whom Masterson is charged with raping.

"The evidence will show that they were drugged," Mueller told the jury. The defense denied such evidence exists.

Direct discussion of drugging was missing from the first trial — which ended in a mistrial when a jury deadlocked on all three counts — with Mueller instead having to imply it through the testimony of the women, who said they were woozy, disoriented and at times unconscious on the nights they described the actor raping them.

However, the judge allowed the direct assertion to be heard at Masterson's retrial.

SCIENTOLOGY SPOTLIGHT: DANNY MASTERSON, TOM CRUISE, AND LEAH REMINI ILLUMINATE HOLLYWOOD CHURCH DRAMA

Danny Masterson then and now split

Masterson gained fame on "That '70s Show." (Peacock YouTube Channel/Getty Images)

According to Kutcher's letter, Masterson set an "extraordinary standard" for how to treat other people as he recalled a time the actor stood up for a girl at a pizza parlor who was being berated by a "belligerent man." 

"We had never met or seen these people before, but Danny was the first person to jump to the defense of this girl. It was an incident he didn't have to get involved in but proactively chose to because the way this man was behaving was not right. He has always treated people with decency, equality and generosity," Kutcher wrote.

Kutcher's wife Kunis, who also starred on "That '70s Show," noted that Masterson became an "outstanding older brother figure to me" during their friendship.

LEAH REMINI PRAISES DANNY MASTERSON PRISON SENTENCE: ‘RELIEVED THIS DANGEROUS RAPIST WILL BE OFF THE STREETS’

Cast of "That '70s Show" in a promotional picture

Masterson starred alongside Mila Kunis and Ashton Kutcher on "That '70s Show." (FOX Image Collection via Getty Images)

"One of the most remarkable aspects of Danny's character is his unwavering commitment to discouraging the use of drugs. His influence on me in this regard has been invaluable," Kunis wrote. "In an industry where the pressures and temptations of substance use can be overwhelming, Danny played a pivotal role in guiding me away from such destructive paths."

She added, "His dedication to avoiding all substances has inspired not only me but also countless others in our circle. Danny's steadfastness in promoting a drug-free lifestyle has been a guiding light in my journey through the entertainment world and has helped me prioritize my well-being and focus on making responsible choices."

Kunis wrote that she "wholeheartedly vouch for Danny Masterson's exceptional character and the tremendous positive influence he has had on me and the people around him."

CLICK HERE TO SIGN UP FOR THE ENTERTAINMENT NEWSLETTER

Danny Masterson holds a cup of coffee while walking into courthouse with wife Bijou Phillips

Masterson was supported by his wife, Bijou Phillips. (Myung J. Chun)

Masterson's wife, Bijou Phillips, also wrote a letter explaining the actor had been a "life-saving" partner to her.

"Danny is an amazing father. Our daughter and I are heartbroken that he is not home with us. It has been very difficult without him here. Even though he is now in jail, he calls her every day. He helps her with homework every night. He teaches her math with kindness and patience. She is far above grade level in all subjects, reading three grades above her own, and that is thanks to the guidance and attention of her father. Danny has watched her piano recitals and applauds when she practices in the living room after each song. Our daughter loves her pony on our farm, as well as our dogs and cats. But more than anything, she loves her father. When he calls us each day, she ends with 'I love you too much Daddy,'" she wrote.

Phillips added: "We need him more than you can imagine. I know he has been convicted of serious crimes. But the man I married has only been an extraordinary husband to me and a devoted father to our daughter."

CLICK HERE TO GET THE FOX NEWS APP

Danny Masterson wears a blue suit and sunglasses while arriving to court for rape trial in LA

Masterson was convicted of two counts of rape after a mistrial last year. (Myung J. Chun)

Los Angeles County Superior Court Judge Charlaine Olmedo sentenced Masterson to 15 years to life on each count of rape, and ordered the sentences to be served consecutively. The sentence was the maximum allowed by law. It means Masterson will be eligible for parole after serving 25.5 years but can be held in prison for life.

Masterson's legal team immediately announced plans to appeal, citing "substantial" errors in the trial.

"For the past several months a team of the top appellate lawyers in the country has been reviewing transcripts of the trial. They have identified a number of significant evidentiary and constitutional issues which they will address in briefs to both the state and federal courts," Masterson's lawyer, Shawn Holley, said in a statement provided to Fox News Digital.

"The errors that occurred in this case are substantial and, unfortunately, led to verdicts that were not supported by the evidence. And though we have great respect for the jury in this case and for our system of justice overall, sometimes they get it wrong. And that's what happened here."

Holley added, "Mr. Masterson did not commit the crimes for which he has been convicted and we, and the appellate lawyers, the best and the brightest in the country, are confident that these convictions will be overturned."

The Associated Press contributed to this report.