(CNN)Serena Williams had to leave the Rogers Cup final in Toronto early Sunday, plagued by back spasms, the Women's Tennis Association said.
The 23-time Grand Slam champion made it though four games of the opening set, but was forced to retire from the match when the pain became too much, WTA said.
Her opponent, 19-year-old Bianca Andreescu, took the title in front of a hometown crowd. But instead of immediately celebrating, Andreescu rushed to comfort Williams, who was visibly upset on the sideline.
"I started tearing up because she was tearing up," Andreescu said during a post-match press conference. "It's because I know how she feels. Injuries really, really suck."
The young player, who had been nervous to face the legendary champion on the court, ended up giving Williams a pep talk.
"I just said, 'Girl, you are ... a beast. You're going to bounce back. You've dealt with so much in your career. This is just a minor setback for a major comeback," Andreescu said.
Williams told reporters she was touched by the gesture. "I was really sad and she made me feel a lot better, so that was really nice."
"She's just a fabulous personality," Williams said of Andreescu in a video posted by WTA.
"She's only 19," she added. "She definitely doesn't seem like a 19-year-old in her words, on court, and her game, her attitude, her actions."
Williams' back pain began Saturday
Williams' back pain began Saturday night during her semifinal match with Marie Bouzkova, and the pain became worse overnight, WTA said.
"My whole back just completely spasmed, and to a point where I couldn't sleep and I couldn't really move," Williams said.
Williams said she probably would have played better if there was more time for treatment between matches, but WTA tournaments are typically played on consecutive days.
"That's the most frustrating part. I've had this before and it's, like, 24, 36 hours where I'm just in crazy spasm and then it's, like, gone. And so that's a little frustrating for me because I know that I could play, I just can't play today," Williams said in the video.