Home / Costa Rica / History

Costa Rica: Independence Movement

by Strong Americas | Aug 10, 2026

Costa Rica's separation from Spanish rule in the early nineteenth century unfolded with unusual calm compared with the prolonged conflicts that marked independence elsewhere in Spanish America. As a remote and sparsely populated province within the Captaincy General of Guatemala, colonial Costa Rica had long been governed with limited direct oversight from Spain, and Napoleon Bonaparte's 1808 invasion of Spain, which destabilized the Spanish monarchy and fueled independence movements across Latin America, had comparatively little immediate effect on daily life in the province.

On September 15, 1821, authorities in Guatemala City declared the independence of the Captaincy General of Guatemala, a decision covering Costa Rica and the other Central American provinces. Because of the region's isolation and the slow pace of communication at the time, news of the declaration did not reach Costa Rica until more than a month later. Local leaders were then left to decide how to respond, and opinion split along regional lines: conservative factions centered in Cartago and Heredia favored aligning with Agustín de Iturbide's newly formed Mexican Empire, while more progressive leaders in San José and Alajuela argued for full independence and a republican form of government.

The disagreement led to brief armed conflict in 1823, known as the Ochomogo War, in which republican forces prevailed. Costa Rica subsequently joined the United Provinces of Central America before that federation dissolved in 1838, after which it emerged as a fully sovereign republic.

Sources: Britannica - Costa Rica: Independence; Wikipedia - Act of Independence of the Republic of Costa Rica
EN ES ES PT