In 1515, the Spanish established Villa de San Cristóbel de la Habana as their first town in Cuba because of the large, natural bay. Five years later, they created the Port of Havana to harbor their Fleet of the Indies during their trade routes between Spain and the New World. It was not long before ships laden with treasures attracted the attention of pirates. To defend against the attacks, the Spaniards built four fortresses from 1590 through 1774. In the background is one of them: Castle of the Morro. As navigational trade flourished, so did the city. The port was extensively expanded between 1790 and 1850. In 1898, the battleship USS Maine exploded and sunk in the harbor. This aggression sparked the Spanish-American War leading to the end of Spanish control. The American’s invested in the port’s infrastructure for a few years until 1902 when the Republic of Cuba was formed. Further enhancements during the 20th century have been limited.