Three-time champion Federer beat 13th seed Medvedev 6-4 6-2 in a rain-delayed clash carried over from the previous day.
He had little trouble on the way to victory needing only 61 minutes to prevail in a match where he committed a mere eight unforced errors.
Federer and Medvedev split the first eight games, and then things turned quickly.
Federer broke his opponent for a 5-4 lead in the first set, fought off three break points to close out the set in the next game, and got another break to open the second set. He cruised home from there.
“I’m feeling really good,” said Federer. “Today’s match, I can be really happy with so I hope it’s going to give me some confidence for tomorrow.
“When you want to go deep in tournaments, sometimes you need those 15 minutes that go your way and you’re able to pull away with the score too,” Federer said of the break and then the rally from 0-40 down to serve out the opening set.
“Margins are super-slim and you need a bit of help sometimes from your opponent.”
Now, to win what would be his fourth Miami title, Federer will have to be victorious four times in a five-day time-frame and next prevail over No 6 seed Anderson.
It’s a match between the two highest seeds left on the men’s side and the biggest test yet for Anderson since his return from an elbow issue.
Federer leads the head-to-head against Anderson 5-1, with the loss coming last year in the Wimbledon quarter-finals where Anderson won 13-11 in the fifth set.
Elsewhere in the draw the defending Miami champion John Isner has already become the first man in the field to reach the semi-finals.
The seventh-seed ousted Roberto Bautista Agut 7-6 (7-1) 7-6 (7-5) and has now won 10 straight matches at the tournament. Isner is yet to drop a set yet in this year’s edition at Hard Rock Stadium; 8-0 in sets, 7-0 in tiebreaks.
He’ll face 18-year-old Felix Auger-Aliassime of Canada in the semi-finals, after the teen toppled Borna Coric 7-6 (7-3) 6-2 on Wednesday night.
In the women’s competition, second-seed Simona Halep also finished her match on Wednesday with a flourish and a return to the top spot in the world could be her reward.
Halep beat 18th-seeded Qiang Wang 6-4 7-5 in the quarter-finals and won the final six games against Qiang.
If she wins her semi-final match then she would return to No 1 in the world and faces fifth-seeded Karolina Pliskova in the last four. Pliskova beat unseeded Marketa Vondrousova 6-3 6-4 to create that meeting.
“I just found out from my coach that I need one more match to be No 1 again,” said Halep. “It’s pretty much in my head and I’m happy that I’m in this position again.”
The duo are two highest seeds left in the women’s draw and the Romanian leads the head-to-head tally against her opponent 7-3.
“It’s going to be, I think, a good match,” added Pliskova. “With her the quality of the tennis is always good and the intensity is always good.”
The other women’s semi-final, set for Thursday afternoon, has Ashleigh Barty facing-off against Anett Kontaveit.