Jozy Altidore gave the hosts the lead before Marc-Andre ter Stegen scored an embarrassing own goal.
Heiko Westermann pulled a goal back for Germany, but Clint Dempsey struck twice in four minutes to make it four for the hosts.
Max Kruse and Julian Draxler made things interesting with late goals, but the United States held on for victory.
After Arsenal's Per Mertesacker wasted a good early chance to give Germany the lead, he then slipped up at the back, leaving Altidore unmarked to volley Graham Zusi's cross in to give the United States a 13th-minute lead.
Three minutes later, Germany goalkeeper ter Stegen made a costly blunder as he helped Benedikt Howedes' backpass into his own goal.
Ter Stegen was almost caught out again as Altidore tried his luck from the halfway line, but sent his shot over the crossbar as the Borussia Monchengladbach custodian fell over on his way back towards his goal.
Andre Schurrle could have brought Germany back into the game, but shot wide, while a Miroslav Klose effort was ruled out for offside.
Westermann reduced the arrears in the 52nd minute with a determined header from a corner, but as Germany pushed for an equaliser, Dempsey restored the hosts' two-goal lead with a volley past ter Stegen.
Dempsey then curled a 20-yard effort beyond ter Stegen's reach to put Klinsmann's men in control of the game.
Germany did not give up, though, and Kruse opened his account with a finely-placed shot past Howard.
Draxler followed suit with his first Germany goal just two minutes later, but there was not to be an equaliser on a hot afternoon in Washington DC.