Ramirez had a first-inning single and scored the game's first run and his two-run single keyed the fourth-inning rally that put Chicago ahead 6-2.
Tyler Flowers knocked in two runs for the White Sox, doubling in the fourth and adding his ninth home run of the season in the sixth.
Jake Peavy (8-4) allowed four runs on four hits and a pair of walks while striking out seven over seven innings. Matt Lindstrom had an inning of no-hit relief and Addison Reed pitched a one-hit ninth for his 26th save.
Chicago pinned the loss on Justin Verlander (10-8), who was charged with seven runs -- all earned -- on 11 hits in six innings.
Torii Hunter connected for a two-run home run in the fourth off Peavy but Flowers had a run-scoring double ahead of the two-run single by Ramirez. Alex Rios singled to allow Ramirez to score, putting the White Sox up 6-2.
Notable deaths of 2014 [PHOTOS]