L.A. County Superior Court Judge Marsha Revel ordered Lohan to serve 30 days in jail on reckless driving, 30 more days for her first DUI charge, and 30 more days for the second DUI. Lohan will serve 90 consecutive days in jail.
Lohan is ordered to undergo a 90-day inpatient drug treatment two days after her release from jail.
Lohan is ordered to surrender to the court on July 20.
The 24-year-old actress broke down in tears as the judge read the sentence. Lohan had made an emotional appeal to the judge asking for leniency moments before.
"I wasn't missing the classes just to hang out or do anything like that, I was just working, mostly in Morocco," Lohan said to the judge before the sentencing. "This trip I was working with children. It wasn't a vacation, it wasn't some sort of a joke. And I respect your word and I've been taking it seriously."
Judge Revel scheduled the hearing after Lohan missed a court date in May. Lohan has been required to wear an ankle alcohol monitor since then.
The monitor issued an alert after Lohan attended the MTV Movie Awards and after-parties.
Prosecutor Danette Meyers said she believes Lohan drank alcohol and violated the terms of her probation. The court had considered hearing testimony regarding Lohan's ankle alcohol monitor. Judge Revel ruled not to consider the alcohol-monitoring ankle bracelet. Instead she would only consider whether the actress failed to complete the required number of alcohol-education courses on time.
"Did she go every week, as ordered?" asked Judge Revel. "If she didn't go, were there a number of times she didn't show up? Did she get there late? Did she say she was going one place and didn't go to that place?"
"The fact that she clearly violated your order, or any judge's order," said Meyers. "When the judge orders you to do something and you don't do it, it's a violation. It's an easy violation."
The alcohol program administrator told the court Lohan missed seven weeks of classes. "We ended up non-complying her in September when she violated the program," said Cheryl Marshall, co-owner of Right On Program.
Lohan said she thought she was excused from some of those classes, and thought she was following the rules. "I figured, and as far as I knew, they were OK with this, and it was still in compliance, that if I did three in a week, or two in a week, then it would make up for the fact that if I had to work the next week, then that's why I wouldn't be there, because I've already done them now. So I thought, as far as I knew, that was in compliance. Had I not known, had I been taken aside and told that in detail, then that would have been a different story. I'm not taking this as a joke. It's my life," said Lohan before she was sentenced.
Lohan is to be jailed at the Century Regional Detention Facility in Lynwood, but it's likely that she'll serve only a fraction of that time.
ABC news legal analyst Dana Cole said the judge's ruling Tuesday probably ties into Lohan's previous run-ins with the law.
Lohan spent 84 minutes in jail in 2007 after she pleaded guilty to two misdemeanor counts of being under the influence of cocaine and no contest to two counts of driving with a blood-alcohol level above 0.08 percent and one count of reckless driving.
"Quite frankly, your honor, she's in violation," Meyers said. "Once, maybe you could excuse. Twice, an oversight. Three times, you still haven't caught her attention. Four times, she just doesn't care. Seven times, the court is irrelevant to her."
Last October, Lohan had asked for a yearlong extension of her three-year probation so that she could complete her alcohol-education classes.
Lohan arrived about 10 minutes early for the hearing Tuesday. Lohan's father, Michael, also attended Tuesday's hearing.
Afterwards, Michael Lohan expressed concern for his daughter.
Asked how he felt, Michael Lohan said, "Pretty beat up. For her more than me."
The Associated Press contributed to this story.