Gonzalez (14-6) allowed three runs on nine hits and struck seven while chipping in on offense with a two-run home run in the second inning.
The win extended Washington's winning streak to five games and sent the Astros to their 33rd defeat in 37 games.
Ryan Zimmerman had two hits and scored the winning run in the seventh inning on a throwing error by Houston third baseman Matt Downs.
Justin Maxwell had two hits and an RBI for Houston. Ben Francisco drove in a ninth-inning run that cut Washington's lead to one.
Armando Galarraga (0-2) took the loss after allowing three runs on six hits and six walks over five innings.
N.J. man wakes up from 10-hour sleep with knife in back
Campus cop fatally shoots Texas student during traffic stop