Mexicans of European descent officially in force through the rest of the colonial period. Criollo resentment of the privileges afforded to the "Peninsulares" was the main reason behind the Mexican War of Independence. When the war ended in 1821, the new Mexican government expelled the peninsulares (approximately 10,000 – 20,000 people) in the 1820s and 1830s which at a degree, kept the European ethnicity from growing as a percentage; this expulsion however, did not lead to any permanent ban on European immigrants, even from Spain. Independence did not do away with economic and social privilege based on race as the Criollos took over those
Mexican War of Independence of Iguala, Iturbide persuaded Guerrero to join his forces in support of this conservative independence movement. A new army, the Army of the Three Guarantees, was placed under Iturbide's command to enforce the Plan of Iguala. The plan was so broadly based that it pleased both patriots and loyalists. The goal of independence and the protection of Roman Catholicism brought together all factions. Iturbide's army was joined by rebel forces from all over Mexico. When the rebels' victory became certain, the Viceroy resigned. On August 24, 1821, representatives of the Spanish crown and Iturbide signed the Treaty of Córdoba, which