A rematch of their classic 2008 title decider, won in five pulsating sets by Nadal, had been anticipated more than any match for years at the All England Club and it did not disappoint.
The final stages were packed full of extraordinary tension and drama, with Nadal saving four match points but, after three hours and two minutes, it was Federer, a month shy of his 38th birthday, who clinched a 7-6 (3) 1-6 6-3 6-4 victory and the chance to take on Novak Djokovic on Sunday.
Should he win, it would give the ageless Swiss a ninth Wimbledon title and take him to 21 grand slam trophies, three ahead of Nadal and six clear of Djokovic.
Djokovic had earlier beaten Roberto Bautista Agut, of Spain, in four sets.
But the romantics out there were waiting for a clash for the ages between Federer and Nadal - and it did not disappoint.
This was Federer and Nadal's 40th meeting, a clash of styles and personalities that dates back 15 years and continues to capture the imagination like nothing else in sport.
Nadal had won 24 of their previous 39 matches and 10 of 13 at the slams but victory for Federer in the 2017 Australian Open final had shown him that he could win again when it mattered most.
Indeed, Nadal had not beaten Federer on a surface other than clay since 2014, ending a run of five straight defeats in the semi-finals of the French Open last month.
They served up a fantastic match, featuring astonishing rallies and brutal power against classic grace.
But it was the Swiss ace who finally triumphed, taking the win on the fifth match point.