Franmil Reyes smacked a leadoff double off Jake McGee (1-3) in the seventh. McGee struck out the next two batters and right-hander Steve Cishek came on to face righty Gomes, who hit a soft liner to right on a 3-2 pitch, scoring Reyes.
''Cishek is definitely never a comfortable at-bat. You just have to try to zone him up, get yourself in a good count and that's kind of how I went,'' said Gomes, who played for the Nationals from 2019-21. ''I think I would have walked if I take that pitch. You guys know me, I swing at everything. Just happy it went my way.''
Erich Uelman (1-1) pitched 2/3 of an inning for his first major league win. Steven Brault, who was activated from the COVID-19 injured list before the game, threw two scoreless innings and Rowan Wick pitched the ninth for his eighth save.
P.J. Higgins homered and Reyes had two doubles for Chicago, which has won four straight series.
Lane Thomas had two doubles for Washington and rookie Joey Meneses extended his hitting streak to 11 games for the Nationals, who have lost five of seven.
''I think we're playing good baseball,'' manager Dave Martinez said. ''Our defense is playing a lot better. Today it was just, there was no run production. I thought we had a chance to win the game, we just couldn't score runs.''
Cubs starter Drew Smyly, who had tossed 11 2/3 scoreless innings over his past two starts, allowed two runs on four hits in 5 1/3 innings. He struck out four without a walk on 100 pitches and retired nine straight batters at one point.
''It was kind of a grind. Lot of foul balls, couple long ABs,'' Smyly said. ''My fastball I think had a lot of life today. It was really good. My curveball not so much.''
Smyly has a 1.06 ERA in August, with 17 strikeouts and three walks.
Nationals starter Cory Abbott, a former Cub, gave up two runs on three hits in a career-high six innings. He matched his career best with five strikeouts.
Higgins' two-out, two-run homer in the fifth gave the Cubs a 2-1 lead.
With runners on first and third and one out in the sixth, Nelson Cruz hit into what was initially ruled a double play. The Nationals challenged, the call at first was overturned and Meneses scored from third to tie it 2-2.
Higgins has six homers this season and the last three have come with Smyly on the mound.
''Yea, he mentioned it to me,'' Higgins said. ''I wish they'd pitch him more than every five days.''
Meneses' hitting streak is now the third-longest by a rookie in Nationals history (2005-present). According to the Elias Sports Bureau, only Ryan Zimmerman (17 in 2006) and Steve Lombardozzi (13 in 2013) have recorded longer hitting streaks as rookies.
Cubs: LHP Wade Miley (shoulder strain) allowed one unearned run on two hits over five innings in a rebab start for Iowa on Tuesday.
Nationals: RHP Erick Fedde (shoulder inflammation) pitched four scoreless innings and allowed three hits in a rehab start for Triple-A Rochester on Wednesday.
Cubs: RHP Adrian Sampson (0-3, 3.88 ERA) starts at Baltimore on Thursday in the makeup of a game rained out on June 8. He allowed three runs on six hits in 5 1/3 innings in a July 12 loss to the Orioles.
Nationals: RHP Anibal Sanchez (0-5, 7.20) pitches the opener of a four-game series on Thursday at San Diego. He allowed three runs on six hits in five innings of a home loss to the Padres in his last start.
More AP MLB: https://apnews.com/hub/MLB and https://twitter.com/AP-Sports
Copyright 2023 STATS LLC and Associated Press. Any commercial use or distribution without the express written consent of STATS LLC and Associated Press is strictly prohibited.