Antigua was first settled by the Spanish in 1527. It was built by Spanish architects and Mayan labourers. During June 1773, a series of earthquakes shook Antigua and many of the citizens abandoned the city for countryside. The tremors continued into the next month, and on July 29, a new tremor longer than all the others left the city in ruins. Aftershocks continued for months, food and water were in short supply, and disease ravaged the survivors.
Most of the inhabitants eventually relocated, though Antigua was never entirely abandoned. For a while, the city was important in the production of cochineal, a dye made from an insect which fed on the cactus cultivated in the area. A new prosperity and a rise in population came late in the nineteenth century, with the introduction of coffee cultivation.