MIAMI GARDENS, Fla. — Roger Federer won a battle of the ages Friday, beating 19-year-old Canadian Denis Shapovalov 6-2, 6-4 in the semifinals of the Miami Open.

Federer, a three-time tournament champion, advanced to Sunday's final against defending champion John Isner.

The age gap with Shapovalov was the largest of the 37-year-old Federer's career, and experience triumphed. Federer used a wide array of shotmaking to take control with two early breaks, and he lost only eight points on his serve.

Despite the loss, Shapovalov will climb to a career-best No. 20 in the rankings.

Federer, seeded No. 4, improved to 17-2 this year. He lost in this month's Indian Wells final to Dominic Thiem.

Isner also advanced by beating a Canadian teenager, 18-year-old qualifier Felix Auger-Aliassime, 7-6 (3), 7-6 (4).