Promoters Rugby International Marketing, the commercial arm of USA Rugby, confirmed the clash on Monday and said that tickets would go on sale on March 13.
"This summer is a vital period for us as we continue the countdown to the Rugby World Cup in 2019 and another fixture helps us along the way in our preparation and enables us to test ourselves further," Gatland said.
The test in Washington will be Wales' fifth on U.S. soil, although all previous clashes there have been against the hosts.
News that makes sense
Your trusted source for staying up-to-date with the world around you. Get free daily news updates and analysis, straight to your inbox.
"The opportunity to expand the already great Welsh support base and Welsh brand is very exciting for us as especially in such a large demographic and audience as the U.S.," said Welsh Rugby Union Group CEO Martyn Phillips.
"The match in Washington allows us to take Springbok rugby to America and to potentially expand the team's appeal to a very large audience," South Africa Rugby CEO Jurie Roux said.
(Reporting by Shrivathsa Sridhar in Bengaluru, editing by Pritha Sarkar)
