Odorizzi (7-8) allowed one run and three hits in seven innings to beat the team that took him 32nd overall in the 2008 draft.
The Rays had won nine in a row before a 3-2 loss Sunday to Boston. The winning streak was the second longest in team history.
''Our guys have a good vibe right now,'' Tampa Bay manager Joe Maddon said.
Tampa Bay took a 2-1 lead in the sixth when Loney drove in two with a two-out, bases-loaded single off Kyle Lohse (11-5), who gave up two runs and four hits over six innings.
''The right guy up at the right time,'' Odorizzi said.
Mark Reynolds put the Brewers ahead 1-0 with his 18th homer of the season in the third.
After Brad Boxberger struck out the side in the eighth, Jake McGee got the final three outs for his 12th save in 13 chances.
Lohse benefited from a key defensive play in the fifth when Reynolds, the first baseman, ran down Logan Forsythe's bloop hit that went into foul territory. Reynolds threw the ball to shortstop Jean Segura, who then made a relay throw to get Forsythe at third.
Lohse was coming off a pair of victories in which he had allowed two runs in 13 2/3 innings. The right-hander dropped to 5-4 in 12 games against the Rays.
''It was frustrating,'' Lohse said of the sixth inning that included two walks. ''I thought I made some good pitches. It was a tough one. Leave it at that.''
Tampa Bay right fielder Kevin Kiermaier made nice catches on balls by Khris Davis and Reynolds during the fifth. Ben Zobrist went 1 for 3 with a sixth-inning walk and has reached base in 11 of his last 16 plate appearances.
''The ball K.D. hit, the ball Reynolds hit, at our ballpark and a lot of other ballparks, those are home runs,'' Brewers manager Ron Roenicke said.
This is just the third series between the teams and the first at Tampa Bay since June 2005. The Rays have won five of seven against the Brewers.
''It was an outstanding night made even better because we did win the game,'' Maddon said.
Brewers: Second baseman Scooter Gennett was back in the starting lineup for the first time since hurting his right quadriceps last Tuesday. He struck out in all three at-bats.
Rays: Catcher Ryan Hanigan, out with a strained left oblique, could return this weekend.
Brewers: Right-hander Matt Garza (7-7), the 2008 ALCS MVP with the Rays, will start Tuesday night's game. ''He's not afraid, man,'' Maddon said.
Rays: Right-hander Alex Cobb (6-6) will oppose Garza.
The theme for the Rays' road trip to Oakland next week is formal wear. The clubhouse equipment room was used Monday as a tuxedo fitting room.
Figure skater Felicia Zhang threw the ceremonial first pitch after being lifted into the air by her skating partner Nathan Bartholomay.
Roenicke and Maddon were coaches together with the Angels. ''Joe is out there, but he's got great common sense and you don't usually see that in a guy that's out there.'' Roenicke said ''When he explains something to you, it makes total sense.''