Mary Steenburgen credited her husband of 21 years, actor Ted Danson, for helping her overcome a dark past.

“My dad had a series of heart attacks when I was a little girl, and our world was shaped by these huge traumatic events,” the 64-year-old actress told Closer Weekly. “I spent my childhood waiting for my dad to die. From the age of eight, my response to that insanity was to bury myself in books, where if people died, they could get back up again.”

Two years after the Arkansas native landed her breakout role in the 1978 film “Goin’ South,” she married her first husband, English actor Malcolm McDowell, in 1980. After giving birth to her daughter Lilly McDowell, she won an Oscar for the 1980 film “Melvin and Howard.”

“I had Lilly, my first child, two and a half months before that,” she explained. “I was so crazy in love with my daughter that it slightly eclipsed the Oscar — which in Hollywood is an almost sacrilegious thing to say.”

Steenburgen also gave birth to a son named Charlie McDowell in 1983. She and Malcolm McDowell separated in 1989 and divorced in 1990.

She added that during tough times, she watched her future second husband on TV.

“I always though Ted was brilliant,” she said. “When I was going through sad times, I’d watch ‘Cheers’ at the end of the day to make me feel better. Then I discovered it was easier to just sleep with Sam the bartender.”

The couple married in October 1995.

Today, Steenburgen said she’s happier than ever with the “ridiculously talented” 69-year-old, who continues to support her own Hollywood career.

“I shoot [Fox’s] ‘The Last Man on Earth’ from August to February, and Ted shoots [NBC’s] ‘The Good Place’ from February to August, so there’s never a time when we’re both free,” she said. “We help each other learn lines every night.”