LONDON (AP) -- As usual, Roger Federer is looking to add to one of his many records. And as many expected, Novak Djokovic will be trying to stop him.
The top two players in the world advanced to the championship match at the ATP finals on Sunday, each looking beatable early before turning things around.
Federer, a six-time champion at the season-ending event, advanced by beating U.S. Open champion Andy Murray 7-6 (5), 6-2. The top-ranked Djokovic defeated Juan Martin del Potro 4-6, 6-3, 6-2.
"I knew that if I lose today it's the end of the season, so I gave everything I had and couldn't be more happy," Federer said on court after the match.
The ATP finals is the last tournament of the season, and Federer will face Djokovic in the final match on Monday at the O2 Arena.
Federer found himself in a hole early against Murray, losing his serve in the opening game. But Murray, who lost to Federer in the Wimbledon final but beat him in the Olympic final, couldn't hang on. The 17-time Grand Slam champion broke back to even the score at 4-4, then recovered from a 3-1 deficit in the tiebreaker to win the opening set and take control.
In the second set, Federer lost only two points on serve and broke Murray twice.
"Once he gets ahead, he's incredibly hard to stop," said Murray, who leads Federer 10-9 in head-to-head play. "He tends to play better and better when he gets up. I feel like I gave him that advantage the beginning of the second set."
In the early match, the top-ranked Djokovic started playing his best tennis as soon as he appeared on his way to an early offseason vacation.
Djokovic was broken late in the first set and again early in the second, but he found his stroke and quickly rebounded.
"Well, I had a little, let's say, crisis in today's match from 4-all, first set to 2-all in the second, where I didn't feel so good on the court, struggling to find my momentum and my rhythm," Djokovic said. "So you try to be positive and push myself to fight for every point and believe I can come back. That was the case."
Del Potro took the lead late in the first set, breaking Djokovic for a 5-4 lead before serving out the set at love.
The tall Argentine, who defeated Djokovic to win the Olympic bronze medal at Wimbledon this year, then went up a break early in the second set. But Djokovic broke right back to 2-2 and then took Del Potro's serve again to take a 5-3 lead.
"He's so good," Del Potro said. "Of course, he's the No. 1. In these kinds of matches, they make the difference between them and the rest of the players."
In the third set, Djokovic decisively won 12 of 13 points over a three-game stretch to take a 3-1 lead. He broke again three games later and held at love to advance.
"I believed that I could come back," said Djokovic, who treated the media to chocolates during his post-match news conference to thank them for their work throughout the year. "I believed that I could turn this match around in my favor, and I've done so."
The victory was Djokovic's 74th of the season, tying him with David Ferrer for the most this year. It was also his seventh win in nine matches against Del Potro.
Djokovic won the ATP finals in 2008 and reached the semifinals in 2009 - the first year the tournament was played at the O2 Arena in London.