Mexico's short recovery after the War of Independence was soon cut short again by the civil wars, foreign invasion and occupation, and institutional instability of the mid-19th century, which lasted until the government of Porfirio Díaz reestablished conditions that paved the way for economic growth. The conflicts that arose from the mid-1850s had a profound effect because they were widespread and made themselves perceptible in the vast rural areas of the countries, involved clashes between castes, different ethnic groups, and haciendas, and entailed a deepening of the political and ideological divisions between republicans and monarchists.