During the salute, Coast Guard members fired blanks on the northwest side of Coast Guard Island in Alameda.
The 21-gun salute dates back centuries to when ships entering friendly ports would discharge their canons to prove they weren't loaded, according to the U.S. Coast Guard.
The salute is currently fired on Presidents Day and the Fourth of July.
It is also used to honor the current president, a former president or a president-elect of the United States.
Other people and entities honored with the salute include the sovereign or chief of state of a foreign nation, a member of a reigning royal family, or a national flag.