The Tigers overcame a three-run deficit with a late surge that ended Chicago's first two-game winning streak of the month.
Chicago took a 4-1 lead through five innings, but Detroit moved in front with a four-run sixth that featured Peralta's key hit. Brennan Boesch added a solo homer in the seventh and an RBI single during a two-run eighth for the Tigers.
Detroit starter Rick Porcello (4-4) lasted five innings and got the win when the Tigers put together their rally in the sixth. Porcello gave up four runs on nine hits and struck out five.
Matt Garza (2-5) was the losing pitcher, although two of the five runs he allowed were unearned. He was touched for seven hits in six innings.