Josh Bell and Ke'Bryan Hayes began the winning rally with singles off Raisel Iglesias (2-3). Bell then scored the tying run on Cole Tucker's single.
One out later, Gonzalez lined out to right field and Tucker easily beat Nick Castellanos' off-target throw.
''I went up there just thinking I'm trying to look at the ball first, and I know if it's a strike then I'm going to swing,'' Gonzalez said.
Gonzalez has worked his way into becoming the everyday shortstop and leadoff hitter and is batting .289. He spent the first five seasons of his career as a bench player.
''We talk about taking advantage of opportunities, about the meritocracy of playing time and he deserves to play,'' Pittsburgh manager Derek Shelton said. ''He's been our best player. He's been outstanding.''
Richard Rodriguez (1-2) pitched a scoreless ninth for the win. He was one of five relievers that held the Reds scoreless over the final six innings, following Geoff Hartlieb, Sam Howard, Chris Stratton and Nik Turley.
The Pirates bullpen was riddled by injuries earlier in the season and closer Keone Kela remains sidelined by right forearm tightness.
''We you pitch that well, you've got to find a way to win the game,'' Tucker said. ''It felt good to string a couple of hits and a sacrifice fly to reward them with a W.''
Reds rookie starter Tejay Anthony was in line for his first major league win after pitching one-run ball over five innings. Castellanos hit a two-run homer.
Anthony allowed five hits while striking out six and walking two. He was making his third career start and eighth appearance.
Castellanos' homer to the Reds' bullpen in left-center field came in the third inning to open the scoring after Joey Votto drew a leadoff walk. It was Castellanos' 12th of the season.
Iglesias was attempting to get a five-out save. He entered to protect a one- run lead in the eighth inning with one out and runners on first and second.
Iglesias escaped that jam by striking out Colin Moran and getting Gregory Polanco to line out. Iglesias, however, couldn't close it out.
''I was trying to focus on pitching in the strike zone and getting a double play,'' Iglesias said of the ninth inning. ''Unfortunately, things didn't go the way I hoped for.''
It was another disappointing loss for the Reds, who are 18-23 despite signing both Castellanos and Mike Moustakas to four-year, $64-million contracts as free agents in the offseaon.
''Every game is an opportunity to go out and compete and with,'' manager David Bell said. ''We still have an opportunity ahead of us, so that's our focus. We have guys that have been in these situations their whole life.''
Gonzalez, Adam Frazier and Hayes each had two hits apiece for Pittsburgh.
Pirates starter Chad Kuhl lasted three innings as his pitch count rose quickly due to four walks. He struck out five while allowing two runs and two hits.
It was Kuhl's sixth start since missing last season while rehabbing from Tommy John surgery on his right elbow.
The Pirates recalled OF Jason Martin from the alternate training site and placed OF Anthony Alford on the 10-day disabled list. Alford sustained a season-ending broken right elbow on Saturday night when he crashed into the fence chasing a home run by Cincinnati's Tucker Barnhart.
Claimed off waivers from the Toronto Blue Jays on Aug. 27, Alford had started four of the previous five games in center field. Tucker figures to get most of the starts in center for the remained of the season.
Reds: RHP Sonny Gray (arm fatigue) is scheduled to pitch Thursday against the Cubs at Chicago, giving him nine days off between starts. He was tagged for six runs in 2/3 of an inning in his previous outing Sept. 1 against the St Louis Cardinals.
Reds: Off Monday then visit the Cubs on Tuesday in the opener of a three-game series.
Pirates: Host the Chicago White Sox on Tuesday to begin a two-game series after having Monday off.
More AP MLB: https://apnews.com/MLB and https://twitter.com/AP-Sports
Copyright 2020 STATS LLC and Associated Press. Any commercial use or distribution without the express written consent of STATS LLC and Associated Press is strictly prohibited.