 It was designated as the capital of British East Florida when the colony was established in 1763; Great Britain returned Florida to Spain in 1783.Spain ceded Florida to the United States in 1819, and St. Augustine was designated the capital of the Florida Territory upon ratification of the Adams–Onís Treaty in 1821.The Florida National Guard made the city its headquarters that same year.