MINNEAPOLIS -- Alex Rodriguez hit three home runs in a game for the fifth time in his career and keyed a ninth-inning rally against All-Star closer Glen Perkins, sending the New York Yankees over the Minnesota Twins 8-5 Saturday night.

The Yankees trailed 5-0 early. Rodriguez hit Perkins' first pitch for a tying homer, and John Ryan Murphy later connected for a three-run shot.

Rodriguez hit 452-foot solo homer in the fourth and a 422-foot drive that made it 5-3 in the seventh. His 424-foot homer in the ninth cleared the center field wall.

More from FoxSports

A-Rod clapped as he trotted around first base after each homer while fans at sold-out Target Field booed. The last time Rodriguez hit three home runs in a game was Aug. 14, 2010, at Kansas City.

Rodriguez has 23 homers this season and 677 in his career. He is now 6 for 10 lifetime against Perkins with two home runs.

With one out and runners on first and third, Murphy hit a 2-2 pitch from Perkins into the flower bed over the right-center field wall.

Perkins (0-2) didn't blow a save chance before the All-Star break, but is 0 for 2 since then. He had allowed just six runs all season before the Yankees tagged him for six.

Adam Warren (6-5) pitched 2 1-3 innings in relief of CC Sabathia. Andrew Miller worked the ninth for his 23rd save.

Torii Hunter hit his 208th career home run with the Twins, passing his mentor Kirby Puckett for sixth in team history and giving Minnesota a 5-0 lead in the third.

Aaron Hicks also homered to give the Twins a 2-0 lead off Sabathia in the first.

Chase Headley's sacrifice fly cut Minnesota's lead to 5-4 in a three-run seventh.

Sabathia was pulled after walking Brian Dozier to load the bases in the sixth.

Warren struck out Hicks on a check swing to end the threat, prompting Twins manager Paul Molitor to protest from the dugout and get ejected by plate umpire Jeff Nelson.

TRAINER'S ROOM

Twins: Minnesota hopes injured CF Byron Buxton (thumb) can start taking batting practice late next week. From there, general manager Terry Ryan said Buxton will head to Florida to continue rehabbing before going out on an official rehab assignment in the minors.

UP NEXT

Kyle Gibson (8-7, 3-19) will try to lower his career 10.95 ERA against the Yankees in Sunday's series finale. The Yankees will start Nathan Eovaldi (9-2, 4.43), who is 4-0 with a 2.97 ERA in his last six starts.