In 1894, Shaw graduated from the United States Naval Academy in Annapolis, Maryland.
On June 11, 1898, he served with Company D of the 1st Marine Battalion during the invasion of Guantanamo Bay, Cuba.
He was recognized for gallantry in action and received a brevet (honorary promotion) to the rank of 1st lieutenant.
He retired April 5, 1921, as a colonel after 30 years of service and died May 16, 1927, at the Naval Hospital at Brooklyn, New York.
Colonel Shaw was a hereditary member of the Military Order of the Loyal Legion of the United States, by right of his father's service in the Civil War.