As Matthew Perry opened up about his battle with addiction, the "Friends" star credited Jennifer Aniston for being there for him "the most" during his struggles.

The 53-year-old actor revealed in his new memoir titled "Friends, Lovers, and the Big Terrible Thing," that he nearly died after battling opioid overuse and was in a coma for weeks – while escaping "death very narrowly."

Perry noted that Aniston called her co-star out for drinking during his tumultuous times.

Aniston, who he nicknamed Jenny, said to Perry "we know you’re drinking."

MATTHEW PERRY REVEALS ‘DARK SIDE’ OF ADDICTION JOURNEY IN NEW MEMOIR, OPENS UP ABOUT NEAR-DEATH EXPERIENCE

"Imagine how scary a moment that was," an emotional Perry expressed during an interview with Diane Sawyer, airing on Oct. 28 on ABC.

Matthew Perry Jennifer Aniston

As Matthew Perry opened up about his battle with addiction, the "Friends" star credited Jennifer Aniston for being there for him "the most" during his struggles. (Getty Images)

"She was the one that reached out the most… I’m really grateful to her for that," he continued. 

Matt LaBlanc, Matthew Perry, Jennifer Aniston and Courtney Cox on "Friends."

(Fans recognized Perry for his popular role as Chandler Bing on the hit sitcom "Friends.")

In his tell-all memoir, Perry noted that out of the "six friends," "one of them was sick," as he referred to himself. He added that behind the scenes his castmates attempted to help him with his challenges. 

"Secrets kill you," Perry said in his interview. "Secrets kill people like me."

Matthew Perry

The 53-year-old actor revealed in his new memoir titled "Friends, Lovers, and the Big Terrible Thing," that he nearly died after battling opioid overuse and was in a coma for weeks -- while escaping "death very narrowly." (Getty Images)

Fans recognize Perry for his popular role as Chandler Bing on the hit sitcom "Friends," however he spoke out and argued there were times he felt extremely alone.

MATTHEW PERRY OPENS UP ABOUT HIS BATTLE WITH ADDICTION: 'BEING ON 'FRIENDS' PROBABLY SAVED MY LIFE'

"At the time I should have been the toast of the town," Perry said, "I was in a dark room meeting nothing but drug dealers and completely alone."

The "Friends" star admitted he took "55 Vicodin a day," in addition to "Methadone, Xanax, a full quart of vodka a day," Sawyer mentioned.

In his memoir, readers will find a chilling letter penned by Perry on the first page.

MATTHEW PERRY: A LOOK BACK AT THE UPS AND DOWNS OF THE 'FRIENDS' ACTOR'S LIFE

"Hi, my name is Matthew, although you may know me by another name, my friends call me ‘Matty,’ and I should be dead."

After Sawyer read the first page of his book, Perry responded with: "Yeah, that’s definitely true."

CLICK HERE TO SIGN UP FOR THE ENTERTAINMENT NEWSLETTER

Perry explained that he decided to speak out now about the life-threatening challenges he faced because "it was important to me to do something that would help people."

CLICK HERE TO GET THE FOX NEWS APP

"Friends, Lovers, and the Big Terrible Thing" is set to be released Nov. 1.