Mexico’s journey to sovereignty is not defined by a single date on a calendar, but rather by a tumultuous eleven-year struggle that reshaped the political landscape of North America. While September 16, 1810, marks the famous Grito de Dolores—the cry that ignited the war—and September 27, 1821, signifies the triumphant entry of the Army of the Three Guarantees into Mexico City, the true answer to "when did Mexico get their independence" requires an understanding of the distinct phases between the spark of rebellion and the formal recognition of a new nation.
The Spark: The Grito de Dolores (1810)
In the early hours of September 16, 1810, Father Miguel Hidalgo y Costilla rang the church bells in the small town of Dolores (now Dolores Hidalgo, Guanajuato). Because of that, he called upon his parishioners—largely indigenous peasants and mestizos—to rise up against the gachupines (Spanish-born peninsulares) who held political and economic power. This event, known as the Grito de Dolores (Cry of Dolores), is universally celebrated as Mexico’s Independence Day.
Still, it is crucial to distinguish between the start of the war and the achievement of independence. That's why hidalgo’s movement was initially a massive, undisciplined social uprising rather than a coordinated military campaign for a defined republic. The early phase (1810–1811) saw stunning initial victories, including the capture of Guanajuato and Valladolid, but ended in disaster at the Battle of Calderón Bridge. Hidalgo was captured, defrocked, and executed in 1811 Simple as that..
The Ideological Evolution: Morelos and the Congress of Chilpancingo (1811–1815)
Leadership passed to José María Morelos y Pavón, a former student of Hidalgo and a far more strategic military mind. Morelos understood that a rebellion needed a political framework. Under his command, the movement gained structure. In 1813, he convened the Congress of Chilpancingo, which produced the Sentimientos de la Nación (Sentiments of the Nation). This document declared independence from Spain, abolished slavery and the caste system, and established Catholicism as the sole religion Easy to understand, harder to ignore..
Morelos drafted the Constitution of Apatzingán (1814), the first constitutional text in Mexican history. And despite these advancements, the royalist forces, led by the formidable General Félix María Calleja, systematically dismantled the insurgency. Morelos was captured and executed in 1815, pushing the movement into a fragmented guerrilla phase led by figures like Vicente Guerrero and Guadalupe Victoria The details matter here. Turns out it matters..
The Stalemate and the Unexpected Turn (1815–1820)
For five years, the war settled into a brutal stalemate. So the royalists held the urban centers and the silver mines but could not eradicate the guerrillas. Because of that, the insurgents controlled the rugged countryside (the tierra caliente and southern mountains) but could not take major cities. The conflict devastated the economy, particularly the mining sector, and created a deep social fracture Surprisingly effective..
The turning point did not come from the battlefield, but from a political crisis in Spain. Here's the thing — in 1820, a liberal revolution in Spain (the Trienio Liberal) forced King Ferdinand VII to reinstate the liberal Constitution of Cádiz. This terrified the conservative elite in New Spain—peninsulares, high clergy, and wealthy criollos—who had previously supported the Crown to maintain order. They feared that a liberal Spanish government would threaten their privileges, the Church’s power, and the social hierarchy It's one of those things that adds up..
The Pragmatic Alliance: The Plan of Iguala (1821)
Seizing the moment, the royalist commander Agustín de Iturbide—who had once hunted insurgents—switched sides. He initiated negotiations with the insurgent leader Vicente Guerrero. Their historic embrace at Acatempan symbolized the unification of the two warring factions Turns out it matters..
On February 24, 1821, Iturbide proclaimed the Plan of Iguala, a political manifesto built on "Three Guarantees":
- Religion: The Roman Catholic Church would be the sole religion. Here's the thing — 2. In practice, Independence: New Spain would become an independent empire (initally envisioned as a constitutional monarchy under a Spanish prince). 3. Unity: All inhabitants—criollos, peninsulares, indigenous, mestizos, and castes—would be equal citizens.
This plan was a masterstroke of political compromise. It appeased the conservatives (preserving the Church and offering a monarchy) and the liberals/insurgents (guaranteeing independence and equality). The Army of the Three Guarantees formed rapidly, sweeping through the territory with minimal bloodshed as royalist garrisons switched allegiance en masse.
The Formal Achievement: The Treaty of Córdoba (August 24, 1821)
The military reality forced the hand of the new Spanish viceroy, Juan de O'Donojú. Recognizing that Spain lacked the resources to reconquer the territory and facing the overwhelming popularity of the Plan of Iguala, O'Donojú met with Iturbide in Córdoba, Veracruz Most people skip this — try not to..
On August 24, 1821, they signed the Treaty of Córdoba. This document formally recognized the independence of the Mexican Empire under the terms of the Plan of Iguala. Here's the thing — it stipulated that if a suitable European prince could not be found to take the throne, a Mexican congress would choose an emperor. This treaty is the de jure legal instrument of independence, signed by the highest representative of the Spanish Crown in the Americas That's the whole idea..
It's where a lot of people lose the thread.
The Consummation: Entry into Mexico City (September 27, 1821)
The final symbolic act occurred on September 27, 1821. The Army of the Three Guarantees, led by Iturbide, marched triumphantly into Mexico City. The following day, September 28, the Declaration of Independence of the Mexican Empire was signed by the Provisional Governing Junta Which is the point..
At this specific moment—late September 1821—Mexico effectively existed as a sovereign state. The Spanish flag was lowered; the flag of the Three Guarantees (green, white, and red) was raised. On the flip side, Spain did not immediately recognize this reality. The Spanish Cortes refused to ratify the Treaty of Córdoba, and the fortress of San Juan de Ulúa in Veracruz harbor remained under Spanish control until 1825.
Quick note before moving on.
The Post-Independence Struggle: Empire to Republic (1821–1824)
Independence did not bring immediate stability. The "when" extends into the difficult birth of the state And that's really what it comes down to. Turns out it matters..
- The First Mexican Empire (1822–1823): With no European prince accepting the crown, Congress proclaimed Iturbide as Emperor Agustín I in May 1822. His reign was short-lived, marked by conflict with Congress, economic bankruptcy, and a republican uprising led by Antonio López de Santa Anna and Guadalupe Victoria (the Plan of Casa Mata).
- The Fall of the Empire: Iturbide abdicated in March 1823 and went into exile (he was later executed upon a failed return in 1824).
- The Federal Republic (1824): On October 4, 1824, the Federal Constitution of the United Mexican States was enacted. Guadalupe Victoria became the first President. This date marks the consolidation of the republican project, distinct from the imperial independence of 1821.
International Recognition
Diplomatic recognition lagged behind military victory Small thing, real impact..
- United States: Recognized Mexico in 1822 (under President James Monroe).
- Great Britain: Recognized Mexico in 1824/1825.
Spain’s Reluctant Acceptance
Spain’s stubborn refusal to honor the Treaty of Córdoba set the stage for a protracted and costly dispute that would shape Mexico’s early foreign relations. While the Spanish Crown retained a foothold in the Americas—most notably the fortress of San Juan de Ulúa, which remained under Spanish control until 1825—its inability to project power beyond the Gulf coast underscored the limits of its imperial reach. The Spanish government continued to dispatch troops and supplies to the Caribbean, hoping to reestablish a foothold that could serve as a bargaining chip in negotiations over Mexico’s sovereignty.
The diplomatic stalemate was punctuated by military incidents that tested Mexico’s resolve. Think about it: in 1822, a Spanish expedition under General Isidro de la Torre attempted to capture the port of Veracruz, only to be repelled by Mexican forces under General Antonio López de Santa Anna. Similar skirmishes along the Gulf coast persisted through the early 1820s, culminating in a more serious confrontation in 1825 when a Spanish fleet briefly blockaded the harbor, prompting a vigorous Mexican response that forced the fleet to withdraw. These clashes, though limited in scope, demonstrated that Spain was unwilling to accept Mexico’s independence on its own terms.
The turning point came after years of diplomatic maneuvering and the broader collapse of Spanish power in the Pacific. On top of that, by the early 1830s, Spain’s colonial empire had been reduced to a handful of scattered outposts, and the cost of maintaining a distant naval presence in the Gulf became increasingly untenable. In 1831, a Treaty of Peace, Friendship, and Navigation was signed between the two nations, but it languished in the Spanish legislature for several years. Finally, on 28 December 1836, the Spanish Cortes ratified the agreement, formally recognizing the United Mexican States as an independent sovereign nation. The treaty also stipulated the withdrawal of Spanish troops from the remaining Caribbean holdings, with the last Spanish soldiers leaving the Americas in 1838.
Legacy of Recognition
The eventual Spanish acknowledgment of Mexican independence closed a painful chapter that had begun with the signing of the Treaty of Córdoba in 1821. It marked the definitive end of Spain’s centuries‑long dominance over the territories that would become modern Mexico and validated the legal framework established by the Plan of Iguala and the subsequent constitutional developments. The delay, however, had lasting consequences: it fostered a deep-seated mistrust of European powers within Mexican diplomatic circles, influenced the nation’s early foreign policy of non‑intervention, and reinforced a domestic narrative of self‑reliance that would guide Mexico’s political evolution throughout the nineteenth century.
From the triumphal entry of the Army of the Three Guarantees into Mexico City in September 1821 to the formal Spanish ratification in 1836, Mexico’s journey from imperial proclamation to internationally recognized republic illustrates the complex interplay of internal ambition and external resistance. On top of that, the nation’s ability to consolidate its sovereignty despite prolonged diplomatic obstinacy underscores the resilience that would define its nascent identity. In the end, the struggle for recognition was not merely a diplomatic formality; it was a testament to Mexico’s determination to carve out an independent destiny amid the waning shadows of empire.