And second-seeded Rafael Nadal ended the run of Paris debutant Juan Ignacio Londero with a typically dominant 6-2 6-3 6-3 victory.
Federer, the 20-time Grand Slam champion, back at Roland Garros after a three-year hiatus, cruised through the opening rounds seemingly unchallenged and his last-16 encounter was no exception.
But things are likely to get trickier for Federer as the third seed will next face his old friend and 2015 champion Stan Wawrinka after the 34-year-old won an extraordinary contest against sixth seed Stefanos Tsitsipas.
The pair battled for five hours and nine minutes on Court Suzanne Lenglen before Wawrinka eventually triumphed 7-6(6) 5-7 6-4 3-6 8-6.
— Roland-Garros (@rolandgarros) June 2, 2019
After just over an hour in his match, Federer was already two sets up but Mayer offered some semblance of resistance in the third until the sixth game, when Federer, 37, broke decisively, ending his opponent’s ordeal on the first match point.
“I served super well and Leonardo had trouble returning. I was able to put pressure on him and I’m very happy with my performance,” Federer said.
Nadal also produced claycourt tennis of the highest quality to make the last eight of a Grand Slam event for the 38th time.
The Spaniard won his 90th match at the French Open as the 11-time champion cruised to victory against the 78th-ranked tournament debutant Londero in two hours and 13 minutes.
Nadal has only lost two matches at the tournament, in 2009 and 2015 and 13th quarterfinal appearance will move him one ahead of world No.1 Novak Djokovic, who can, however, draw level on Monday against German Jan-Lennard Struff.
Nadal must wait until Monday to see who he now meets out of Japanese seventh seed Kei Nishikori or unseeded Frenchman Benoit Paire after their match was suspended due to darkness, with Nishikori leading two sets to one.
9 January 2018
As the first Grand Slam of the season fast approaches, top-10 players are leading the char... More
18 June 2019
Defending champion Marin Cilic has edged his way into the second round at Queen's Club in ... More
8 June 2019
It was deja vu for Roger Federer as his return to Roland Garros ended in another claycourt... More