John Stamos is remembering his friend Matthew Perry, who he credits as being the person who kept him in show business.

On Tuesday, Stamos took to Instagram and shared a clip from an episode of "Friends" when he guest starred on the sitcom as Zach, a potential man who was going to be a sperm donor for Chandler Bing and Monica Geller.

"Matthew and I had been friendly long before ‘Friends’ So, when I guest starred as Zach, the prospective sperm donor for Chandler and Monica, I hung with him a lot," Stamos’ caption began. "Standing backstage, ready to make my entrance, Matt whispers, ‘The audience is going go crazy when they see you! Get ready for some loud screams.’"

APP USERS CLICK HERE

The "Full House" star shared that the audience’s reaction to him being on the show was not what Perry had anticipated.

MATTHEW PERRY CAUSE OF DEATH ‘DEFERRED’: CORONER

"I walk through the door… silence. I was so embarrassed," Stamos revealed. "We finish the scene and as I start to slither back to my dressing room and quit showbiz, Matt walks over to the studio audience: ‘Ladies and gentlemen, give it up for John Stamos! You guys probably didn’t recognize him at first because he’s so much better looking in person!’"

Stamos concluded his tribute with, "I never forgot that and the world will never forget you. #ripmatthewperry"

John Stamos, Matthew Perry

John Stamos, right, revealed Matthew Perry stopped him from quitting showbiz. (Getty Images)

Celebrities around the world have paid tribute to Perry after his sudden passing on Oct. 28.

The "Friends" cast, which includes Jennifer Aniston, Courteney Cox, Lisa Kudrow, Matt LeBlanc and David Schwimmer, issued a joint statement to People magazine on Monday, remembering their late friend and co-star. 

"We are all so utterly devastated by the loss of Matthew. We were more than just cast mates. We are a family," the cast said in the statement. "There is so much to say, but right now we’re going to take a moment to grieve and process this unfathomable loss.

Friends cast eats ice cream

The cast of "Friends" issued a joint statement following the death of Matthew Perry. (NBC)

"In time we will say more, as and when we are able. For now, our thoughts and our love are with Matty’s family, his friends, and everyone who loved him around the world."

Perry died Saturday after an apparent drowning in a hot tub, law enforcement sources confirmed to Fox News Digital. No drugs were reportedly found on the scene, and no foul play is suspected.

Perry admittedly spent upwards of $9 million on his decadeslong substance abuse and sobriety battle. At one point, he was taking 55 Vicodin per day, he wrote in his 2022 memoir, "Friends, Lovers, and the Big Terrible Thing."

Matthew Perry in a black sweater soft smiles in front of red curtain

Matthew Perry was found dead in a hot tub in his Pacific Palisades home on Saturday. He was 54. (David M. Benett/Getty Images)

CLICK HERE TO SIGN UP FOR THE ENTERTAINMENT NEWSLETTER

The actor revealed he had pursued 15 stints in rehab and underwent 14 surgeries for addiction-related medical issues. Perry was also on life support for a brief period and in a coma for two weeks.

Writing the memoir was part of his recovery. He said emotions came "pouring out of me — the painful stuff, hospitals, rehabs, all of this stuff — it poured out of me. It went really quickly." 

Matthew Perry smiles in a black jacket and shirt with clear glasses on the carpet

Matthew Perry was open with his struggle with substance abuse prior to his death. He also revealed in 2021 that he was sober. (Phillip Faraone/Getty Images for GQ)

CLICK HERE TO GET THE FOX NEWS APP

In an October 2022 interview with The New York Times, Perry said he had been sober since early 2021.