Gonzalez (19-7) overcame five walks, allowing three hits while striking out six en route to becoming the major leagues' first pitcher to reach 19 wins.
The left-hander benefited from a pair of double plays turned behind him as the National League East-leading Nationals took the opener of a three-game series.
Collin McHugh (0-2) was tagged with the loss, surrendering five runs (two earned) on five hits in four frames.
Scott Hairston went deep for New York.
Pistorius testifies he didn't consciously pull trigger when he shot girlfriend
Charlize Theron not engaged to Sean Penn 'yet'