Stammen (3-5) was perfect through the first four innings, but David Wright broke it up in the fifth with a single to center.
"When that happens, you are feeling good and ready to rock and roll," Stammen said about those four frames. "You have to keep tricking yourself to think about the next batter and not the next three or four innings."
Stammen was rattled in the sixth inning with Washington leading, 1-0. Angel Pagan led off with a triple to left-center. As Pagan headed to third, shortstop Cristian Guzman caught the relay throw from center fielder Nyjer Morgan and threw toward the third-base bag. But the ball ended up going into the Mets' dugout, which allowed Pagan to score the tying run.
Fernando Tatis followed by doubling down the left-field line. The next hitter, Daniel Murphy, walked, but Wright flied out to end the inning.
Outfielder Josh Willingham made Stammen the winning pitcher in the bottom of the sixth when he sent a 2-1 pitch from right-hander Mike Pelfrey over the left-field wall for a two-run homer. It was Willingham's 13th homer of the season.
Willingham went 4-for-4 in the game and finished a triple short of the cycle. The performance broke him out of an 0-for-14 slump, with all 14 of those at-bats coming in the four-game series against the Cubs.
"I didn't feel like I was in a slump, really," Willingham said. "It was basically four games against Chicago. ... I felt the exact same way that I felt in Houston. I hit a couple of balls to the wall that got caught against the Cubs. If those balls fall, we are not talking about it right now."
Stammen pitched 7 1/3 innings and gave up the one run on four hits. He felt that he could have pitched his second complete game of the season, but with one out in the eighth, he gave up a double to Jeremy Reed and walked Pagan before leaving the game in favor of Jason Bergmann.
"I was mad [about] walking that guy," Stammen said. "I felt that I had three pitches to get him out, and I didn't execute any of them the way I wanted to. The last pitch was close. That's just the way it is sometimes."
Stammen said that he threw almost nothing but sinkers and was able to locate them down and away. And the Mets noticed.
"He threw a lot of sinkers and pretty much said, 'Hit this,' " Mets catcher -- and former Nationals receiver -- Brian Schneider said. "Speaking for myself, I didn't make enough adjustments."
Said Pelfrey: "I went up to hit, and I'm not a great hitter by any means, but he was pretty nasty. You've got to tip your cap. He was on tonight. There are days like that when you run into guys like that, and I'm sure [Tuesday starter John] Lannan was like that last night, too."
Stammen's performance comes a day after Lannan pitched a shutout against New York. Stammen acknowledged that he feeds off his roommate.
"I'm kind of the right-handed version of him a little bit," Stammen said. "We are a lot alike. Hitters don't see us the same way, but he went at guys with his fastball, and that's how I pitch. I had to go out and see if it was working, and it was working the first couple of innings, so I stuck with it.
"John had a tremendous outing, and I wanted to build off it. I was glad we were able to do that."
Bill Ladson is a reporter for MLB.com. This story was not subject to the approval of Major League Baseball or its clubs.