Their joint announcement concluded months of talks about moving the team from aging Oracle Arena in nearby Oakland. The team is due to remain in Oakland until the new arena is completed in time for the 2017-2018 season, according to the club and Mayor Edwin Lee's office.
In San Francisco, where the Warriors played from 1962 to 1971 before moving to Oakland, the team will be in a much larger market and will take a major step toward its owners' ambitions for raising the franchise's profile.
Meanwhile, San Francisco will gain a $400 million to $500 million arena that will seat between 17,000 and 19,000 spectators and also serve as an entertainment venue and convention centre, the team said.
"We are working with the Warriors to get a state-of-the-art, multi-purpose arena built on the waterfront in San Francisco and completed in 2017," Lee said.
The arena will be located on city property near AT&T Park, home of Major League Baseball's San Francisco Giants, that the Warriors will lease.
The Warriors, headed by co-executive chairmen Joe Lacob and Peter Guber, plan to use and raise their own funds for the arena.
Oakland also risks losing its baseball franchise, the Athletics, who share the city's O.co Coliseum with the National Football League's Oakland Raiders.
The owners of the Oakland Athletics have been lobbying Major League Baseball for several years for permission to move the team to San Jose, California's third-largest city, where they would build a new baseball park.