Tennis great Roger Federer has announced his retirement from the sport.
"As many of you know, the past three years have presented me with challenges in the form of injuries and surgeries," Federer wrote in a lengthy note on his social media accounts. "I've worked hard to return to full competitive form. But I also know my body's capacities, and limits and its message to me lately have been clear."
He continued. "I am 41 years old. I have played more than 1500 matches over 24 years. Tennis has treated me more generously than I ever would have dreamt, and now I must recognize when it is time to end my competitive career."
Federer went on to say his final ATP event will be at the Laver Cup next week in London.
Federer had said as recently as Wimbledon that he planned to still return to the game after a lengthy absence due to injuries. The former world No. 1 discussed a possible return during an on-court ceremony recognizing the 100-year anniversary of Wimbledon's Centre Court on July 3.
"I hope I can come back here one more time," Federer told the crowd to loud cheers.
He also admitted how hard it has been for him to come back from his knee injuries, however.
"I would have loved to be here [competing]," he said. "I knew walking out here last year it was going to be a tough year ahead. Maybe I didn't think it was going to take me this long to come back but the knee has been rough on me."
Federer, who turned 41 last month, has won 20 major tournaments. He was the first player to ever win 20, though he has now been passed by longtime rivals Rafael Nadal (22) and Novak Djokovic (21). His 103 titles overall is second all-time in the Open Era behind only Jimmy Connors. He won a gold medal for Switzerland in doubles alongside Stan Wawrinka at the 2008 Olympics and a silver in singles at the 2012 London Games, coming up short to hometown favorite Andy Murray.
He also has the record with 237 consecutive weeks spent at No. 1.
"This is a bittersweet decision, because I will miss everything the tour has given me," he wrote. "But at the same time, there is so much to celebrate. I consider myself one of the most fortunate people on Earth. I was given a special talent to play tennis, and I did it ata level I never imagined, for much longer than I ever thought possible."
Federer's retirement comes just weeks after Serena Williams announced she was stepping away from the game. Federer said on Instagram before what became her final match -- a loss to Ajla Tomljanovic in the third round at last week's U.S. Open -- that he wished her well and congratulated her on her career.
"I wanted to congratulate you on a truly amazing career," he said in the video posted by the ATP and WTA. "You know what you have achieved. I know what you have done and I know and you know it was just amazing."
The two greats played against each other just once in their careers. Federer and his mixed doubles partner Belinda Bencic defeated Williams and her partner, U.S. Open darling Frances Tiafoe, in a match in Australia in January 2019.