Jose Lobaton doubled among his three hits, drove in a run and scored three times for National League East-leading Washington, which pounded out 18 hits against the Giants, including 14 against the bullpen.
''It's unbelievable,'' said Harper of the offensive output. ''Like we said before, a couple days ago, we've got a lot of heart. We want to win every single game.''
Giants reliever Jeremy Affeldt (3-2) allowed five hits and five runs in the sixth without retiring a batter after the departure of starter Ryan Vogelsong.
The Nationals scored six runs in the sixth on eight hits, tying for their most hits in an inning since they began playing in D.C. in 2005. That was just another piece of history during a 10-game homestand that included most of a 10-game win streak, five walk-off wins during a six-game stretch, a 9-1 overall record, and the growth of the division lead over Atlanta to eight games.
''This was a great homestand,'' said Scott Hairston, whose pinch-hit double tied plated the fourth run of the sixth inning to tie it at 6-all. ''I've never experienced anything like it. I think it's safe to say nobody has. And it's a lot of fun.''
Gregor Blanco and Travis Ishikawa homered for the Giants, who ended their road trip 3-3.
Brandon Crawford had three singles for San Francisco, which used its bullpen for 11-2/3 innings across the three-game series.
''They've been terrific,'' said Giants manager Bruce Bochy of his pen, which entered Sunday with a 2.57 ERA, third-best in the majors. ''We turn it over to the pen and they do a great job. Our guys ... I feel for them. They played so well early, and that's a tough one to let get away.''
Strasburg allowed five earned runs -- his most at home since the final game of his innings-limit-shortened 2012 season -- on eight hits and two walks. His day ended when pinch-hitter Nate Schierholtz replaced him and popped out to short to end the fourth.
Vogelsong allowed three runs and three hits, and a season high-tying four walks in 5-1/3 innings. He departed with a 6-3 lead after yielding Desmond's homer.
Harper doubled and scored on Affeldt's wild pitch. Lobaton singled in Asdrubal Cabrera and Hairston's double tied it.