Upton's three-homer performance was the first of his career. The first of the trio came on the first pitch delivered by Rangers starter Roy Oswalt.
He added two more bases-empty clouts off reliever Martin Perez as the Rays took the rubber match of a three-game series.
The shutout was the second of the season for Shields (14-8), who yielded just two hits while striking out eight and not issuing a walk.
The Rays -- who came into the contest 1 1/2 games out of an American League wild card spot -- also got a two-run homer from Jose Molina.
Oswalt (4-3) could manage only two innings, surrendering four runs on six hits for the AL West-leading Rangers.
Celebrity Breakups and divorces of 2014 [PHOTOS]