As the liberal Federation crumbled into civil war due to the influence of the Guatemalan conservatives and the regular clergy, who had been expelled from Central America after Francisco Morazán's bloody invasion of Guatemala in 1829, Los Altos declared itself an independent republic.
[1] The government of Guatemala tried to reach a peaceful solution, but "altenses",[Note 1] protected by the recognition by the Congress of the Central American Federation, did not accept this.
Guatemala's government then resorted to force, sending the commanding general of the army, Rafael Carrera, to subdue Los Altos.
Carrera defeated General Agustín Guzmán when the former Mexican officer tried to ambush him and then went on to Quetzaltenango, where he imposed a harsh and hostile conservative regime for liberals.
[2] General Guzmán and the head of state of Los Altos, Marcelo Molina, were sent to the capital of Guatemala, where they were displayed as trophies of war during a triumphant parade on February 17, 1840.
[3] With the information from these messengers, Carrera hatched a plan of defense leaving his brother Sotero with troops who presented a slight resistance in the city.
Furthermore, unaware of their surroundings in the city, Morazan's troops had to fight, carry their dead and care for their wounded while still tired by the long march from El Salvador to Guatemala.
The disaster for the liberal general was complete: aided by Angel Molina [Note 4] who knew the streets of the city, he had to flee with his favorite men, disguised and shouting "Long live Carrera!"
[9] The defeat of the liberal criollos in Quetzaltenango reinforced Carrera allies' status within the native population of the area, whom he respected and protected as the leader of the peasant revolution.
The new liberal regime allied itself with the Aycinena family and swiftly passed a law which they emphatically ordered the execution of Carrera if he dared to return to Guatemalan soil.
[15] In the meantime, in the eastern part of Guatemala, the Jalapa region became increasingly dangerous; former president Mariano Rivera Paz and rebel leader Vicente Cruz were both murdered there after trying to take over the Corregidor office in 1849.
[15] Upon learning that officer José Víctor Zavala had been appointed as Corregidor in Suchitepéquez, Carrera and his hundred jacalteco bodyguards crossed a dangerous jungle infested with jaguars to meet his former friend.
When they met, Zavala not only did not capture him, but agreed to serve under his orders, thus sending a strong message to both liberal and conservatives in Guatemala City, who realized that they were forced to negotiate with Carrera, otherwise they were going to have to battle on two fronts — Quetzaltenango and Jalapa.
Carrera appointed Ignacio Yrigoyen as Corregidor and convinced him that he should work with the K'iche', Q’anjob’al, and Mam leaders to keep the region under control.