After a decade of strife, Mexico won its independence from the Kingdom of Spain in 1821. After a failed attempt at a monarchy, Mexico adopted a new constitution, the 1824 Constitution. This new constitution established los "Estados Unidos Mexicanos", or "the United Mexican States," as a federal republic. During the war for independence, many rebels were driven to Coahuila and Nuevo León, where this revolutionary mentality won the hearts and minds of the people.