MELBOURNE, Australia -- Roger Federer won his 18th Grand Slam title and put some extra distance on the all-time list between himself and Rafael Nadal, the man he beat 6-4, 3-6, 6-1, 3-6, 6-3 in a vintage Australian Open final on Sunday night.
It was the 35-year-old Federer's first major title since Wimbledon in 2012, his first in Australia since 2010, and it reversed the status quo against his nemesis, Nadal.
Both players were returning from extended layoffs -- Federer for six months after Wimbledon with an injured left knee; Nadal for a couple of months with an injured left wrist -- and were seeded 17th and ninth respectively.
"It's been a different last six months, I wasn't sure I was going to make it here but here I am -- we made it," Federer said after accepting the trophy from Australian great Rod Laver, who lends his name to the main stadium at Melbourne Park.
"I would have been happy to lose too, to be honest. The comeback was perfect as it was. Tennis is a tough sport, there's no draws. If there was going to be one, I would have been happy to have it tonight and share it with Rafa, really."
Federer had lost six of the previous eight Grand Slam finals he'd played against Nadal, and had only previously beaten the left-handed Spaniard in 11 of their 34 matches.
Nadal remains equal second with Pete Sampras on the all-time list, with the last of Nadal's 14 majors coming at Roland Garros in 2014.
He missed his chance to be the first man in the Open era to win each of the four Grand Slams twice. Instead, Federer became the first man in the Open era to win three Grand Slam titles at least five times (Wimbledon 7 titles, U.S. Open 5, Australian Open 5 and French Open 1).
After four sets where the momentum swung alternately from one player to the next, the fifth had all the tension and drama that these two players are famous for.
Nadal went up an early break and it seemed as if the injury time-out Federer needed after the fourth set may have been an indicator of things to come.
But the Swiss star rallied, and broke back in a pivotal sixth game and took control in a period when he won 10 straight points.
Nadal saved three break points in the eighth game but lost momentum again when Federer finished off a 26-shot rally -- the longest of the match -- with a forehand winner down the line.
Consecutive forehand errors gave Federer the pivotal break for 5-3, but Nadal made him work for the very last point.
Serving for the match, Federer had to save two break points with an ace and a forehand winner.
At deuce, he was called for a double-fault but challenged the out call on his second serve. The call was overturned, and he got to play two.
Not long after, he fired an ace to get his second match point and hit a forehand crosscourt winner to finish off.
His celebrations were delayed, though, when Nadal challenged the call. Federer watched the replay on the tournament screen, and leaped for joy when it showed his last shot was in. His 100th match at the Australian Open ended with his fifth title at Melbourne Park.
"Congratulation to Roger ... Just amazing, the way he's playing after such a long time of him not being on the tour," Nadal said. "For sure, you have been working a lot to make that happen. So congratulations."
Nadal spent two months recovering from a left wrist injury before heading to Brisbane for a warmup tournament, breaking his usual routine. He reached the quarterfinals there, and had no expectations of reaching the final in Australia.
"I had some hard time not being able to compete in full condition. ... some injuries, well not new for me, but still tough when it happens," Nadal said. "I fight a lot these two weeks. Today, a great match, probably Roger deserved it a little bit more than me."
No two players had met more often in Grand Slam finals in the Open era, and Nadal had previously dominated. But they hadn't met in a major final since the 2011 French Open, won by Nadal.
Three months ago, they were both on breaks when Federer joined Nadal in Mallorca for the opening of the Spaniard's tennis academy and the pair joked about ever being able to contend for majors again.
Yet here they were, first Grand Slam tournament of the season, renewing the classic rivalry that saw them dominate tennis a decade ago.
The long-odds final -- No. 9 against No. 17 -- unfolded after six-time champion Novak Djokovic was shockingly upset by No. 117-ranked Denis Istomin in the second round and top-ranked Andy Murray, a five-time losing finalist in Australia, went out in the fourth round to left-handed serve-volleyer Mischa Zverev.
Federer beat Zverev in the quarterfinals and U.S. Open champion Stan Wawrinka in an all-Swiss semifinal to reach the championship match. The six years between his Australian titles set a record, too, longer than the five years that both Boris Becker and Andre Agassi had between championships in Melbourne.
It capped a remarkable weekend for 30-somethings -- all four singles finalists were 30 or older -- after Serena Williams beat her sister Venus Williams in the women's final to capture her Open-era record 23rd Grand Slam title.