When the creators of Friends were casting their six stars, the character of Chandler Bing, the one with the jokes, proved among the trickiest.
They weren't sure he was written well enough.
And then in walked Matthew Perry.
"Matthew came in and you went, 'Oh, well, there you go. Done. Done. That's the guy'," David Crane told the Today show in 2019.
"When Matthew reads the dialogue, it sparkles," said Marta Kauffman in the 2021 reunion special. "This was the only guy to play him."
With impeccable comic timing and the distinctive speech patterns that made Chandler unique, Perry created Friends' most quotable character, never failing to nail a punchline. But he also brought warmth, charm and depth to a role that in the wrong hands could have been far less likeable.
The dry humour was often a cover for insecurities and awkwardness, his wisecracks often at his own expense. In real life, he suffered from similar afflictions. Hidden from the public's view during much of the original run of the show was his struggle with addiction to prescription drugs and alcohol, which he detailed in his memoir, Friends, Lovers And The Big Terrible Thing, published just last year.
"Hi, my name is Matthew, although you may know me by another name. My friends call me Matty. And I should be dead," he wrote in the opening.
Born in Massachusetts, Perry grew up in Ottawa, Canada, after his mother, a journalist who once served as press secretary to former prime minister Pierre Trudeau, divorced his father and married a Canadian broadcast personality.
As a child, he became a top-ranked junior tennis player before moving to Los Angeles to pursue acting and improvisational comedy.
When Friends was in the works, Perry was under contract to star in another new series, about luggage handlers working at Los Angeles Airport in the year 2194. But the Friends creators knew they had to have him. It is impossible to imagine Chandler played by anyone else.
"It was as if someone had followed me around for a year, stealing my jokes, copying my mannerisms, photocopying my world-weary yet witty view of life," said Perry of his character. "It wasn't that I thought I could play Chandler; I was Chandler."
When the futuristic airport show failed to make it off the ground, he joined the series that would change his life.
Perry, along with co-stars Jennifer Aniston, Courteney Cox, Matt LeBlanc, Lisa Kudrow and David Schwimmer, became one of Hollywood's most recognisable actors. Relative unknowns before the show launched in 1994, their rise to fame was meteoric; each star reportedly earned $1m per episode at the height of the show's popularity.
Like all the best ideas, the premise was simple: a close-knit group of young adults who shared space in one another's apartments and met for coffee at Central Perk, a fictional Manhattan cafe. It was real life.
One of Chandler's major storylines involved his initially clandestine romance with Monica (Cox), which the four other friends - Rachel (Aniston), Phoebe (Kudrow), Joey (LeBlanc) and Ross (Schwimmer) - each discovered one by one. The One Where Everybody Finds Out is one of the show's greatest episodes.
By the time it came to an end after 10 seasons, Chandler and Monica were married, about to start parenthood, reflecting the journey of the group of friends from single New Yorkers to serious relationships and starting families.
Friends remains one of the biggest TV hits of all time and has taken on a new life - and found surprising popularity with younger fans - in recent years on streaming services. Perry received an Emmy nomination for his portrayal of Chandler and two more for appearances as associate White House counsel Joe Quincy in The West Wing.
His TV work also included the short-lived Studio 60 On The Sunset Strip - written by The West Wing creator Aaron Sorkin - while he starred in several films including Fools Rush In opposite Salma Hayek and his father John, 17 Again, and The Whole Nine Yards alongside Bruce Willis.
However, like his five co-stars, Perry will always be remembered for Friends. It was the show that made him - but with its success also came great pressure, which hit him the hardest. Aniston once described him as "one of the most sensitive people I've ever met".
"Friends was huge," Perry wrote in his memoir. "I couldn't jeopardise that. I loved the script. I loved my co-actors ... I loved everything about the show but I was struggling with my addictions which only added to my sense of shame.
"I had a secret and no one could know.
"I felt like I was gonna die if the live audience didn't laugh, and that's not healthy for sure. But I could sometimes say a line and the audience wouldn't laugh and I would sweat and sometimes go into convulsions...
"If I didn't get the laugh I was supposed to get I would freak out. I felt that every single night. This pressure left me in a bad place. I also knew of the six people making that show, only one of them was sick."
He also recounted how he had to be driven back to rehab right after shooting the episode of Chandler and Monica's wedding. But when the book came out, he seemed to have overcome his demons, announcing at the time that he had been clean and sober for 18 months.
Following his sudden death at the age of 54, there will be thousands of clips shared across social media in the coming days, remembering Perry as Chandler (forgive the non-official titles here): The One Where No One Knew What He Did For A Living. The One With Julia Roberts. All The Ones With Janice. The One Where He Almost Fake-Kissed Phoebe. The One With The Nubbin. The One In The Box. The One With The Shark Porn. The One With The Mr T Bracelet. The One With The Proposal. The One With The Almost Wedding. The One With The Actual Wedding. The One Where They Said Goodbye.
There are too many to list.
Friends was a series greater than the sum of its brilliant parts, thanks to the chemistry between its stars. Each brought something unique, and Perry was the sarcastic, comic beat of the show.
"Matthew is one of the funniest people I've ever met in my life," Kudrow said of her co-star in 2002. "Most of our hard laughs came from Matthew." He was a "true gift" to comedy, as he has been described in tributes, whose "legacy will live on through countless generations".
He was the one who made everyone laugh.
(c) Sky News 2023: Matthew Perry obituary: The one who made everyone laugh