Swiatek continued her strong form that saw her sweep the first two WTA 1000s of the season in her first match since confirming her rise to No. 1.
The 20-year-old Italian erased five match points against Pablo Carreno Busta in a 5-7, 7-5, 7-5 victory.
Medvedev beat Murray 6-4, 6-2 in the fourth round of the season's second ATP Masters 1000 event and will face Spaniard Pedro Martinez next.
In a tense match at Hard Rock Stadium, both men showed off their creative shotmaking, with the picks of the bunch coming in the second set.
Swiatek clinched the top spot with a 6-2, 6-0 victory over Viktorija Golubic of Switzerland in the second round of the Miami Open.
The Australian wild card defeated Andrey Rublev, the fifth seed, 6-3, 6-0, to advance to the third round of the competition.
The 24-year-old from Japan won in straight sets for the second day in a row, this time against 13th seed Angelique Kerber 6-2, 6-3.
The first set was a back-and-forth affair as both players gave their best but Murray used all of his skill and experience for the win.