The arrival of Porfirio Díaz to power marked the end of the nineteenth-century civilian governments that had been headed by figures such as Benito Juárez, Sebastián Lerdo de Tejada and José María Iglesias. This gave way to the establishment of a military regime, which maintained a general in the presidential chair for nearly 30 years.
General Porfirio Diaz's first attempt to reach the Executive Power came in 1871 with the proclamation of the Plan de la Noria, with which he sought to oppose the reelection of then-President Benito Juarez. However, he had the majority support of the population to continue in power due to his notable administration during the conflicts of the Three Years' War, the Second French Intervention, and the imposition of the Second Mexican Empire.
Daniel Cosío Villegas points out that this failed uprising of Porfirio Díaz not only meant a military defeat for a renowned general but also a political defeat by making it clear that during the period of the Restored Republic, Mexicans supported the supremacy of civilian power. This conviction was reflected in 1872 when, after the sudden death of President Juarez, the constitutionalist order was not altered. This allowed the then minister of the Supreme Court of Justice, Sebastián Lerdo de Tejada, to assume the interim presidency in an infallible, prompt, and firm manner, a position that was rectified in Mexico's extraordinary elections of 1872.
Although Sebastián Lerdo de Tejada had opposed the reelection of Benito Juárez, he did not feel obliged not to follow the same path. In 1876 Lerdo announced his intention to run for reelection, a situation that once again caught the attention of Porfirio Díaz, who again pronounced himself against reelection in January of that year with the Plan de Tuxtepec. However, once again, Diaz's movement was seen as just one more "cuartelazo" ("barracks coup").
To counteract this image, on March 21, 1876, in the camp of Palo Blanco, Porfirio Diaz decided to reform the Plan of Tuxtepec. In particular, point number six established that the Executive Power would be deposited in an interim manner in the President of the Supreme Court of Justice, as long as he accepted the Plan; but in case of finding a negative or null response from the Judicial Power, the presidential position would be assumed by the Chief of Arms. Such measure had three objectives in mind for Diaz: first, to give a juridical tone to his uprising; second, to be able to attract to his movement the then Minister of the Supreme Court of Justice, Jose Maria Iglesias, and third, to have control of the Interim President by establishing the condition of seconding the Plan.
Despite the military revolt that devastated some parts of the country, the elections for the four-year term 1876-1880 were held, giving Lerdo de Tejada as the winner, ratified by the Congress of the Union. Given this result, José María Iglesias, as representative of the Judicial Power of the Federation, did not recognize the legitimacy of the elections due to the irregularities presented during the process. By October 1876 Iglesias retired to the area of Guanajuato where he found political support from Florencio Antillón and from that state he called to defend the constitutional principles. He denounced that these had been outraged with the reelectionist decree issued in favor of Sebastián Lerdo de Tejada, who did not have any legitimacy to continue in the position of Executive Power. Thus, Iglesias, following the path of legality, announced that he would assume the position of Interim Constitutional President of the Mexican Republic.
Faced with this situation, Lerdo de Tejada had no choice but to leave the office of President of the Republic and leave the capital on November 20, 1876. However, the presidential situation was not solved; since from the beginning Iglesias had always manifested his opposition to the armed movement supported by Diaz, to the extent of categorically rejecting his proposal to second the Plan of Tuxtepec Reformed in Palo Blanco with a forceful answer: "Either I am the representative of legality or I am not and I do not want to be anything".
This led to a new internal war between the legalist or constitutionalist faction led by José María Iglesias and the military faction headed by General Porfirio Díaz. By the end of November 1876, Diaz had managed to take Mexico City where he declared himself de facto president after his victory against Lerdo.
At the same time of the fighting, José María Iglesias and Porfirio Díaz agreed to meet in mid-December at the Hacienda de la Capilla, Querétaro, to negotiate a peaceful solution to the armed conflict. However, one of the conditions they wanted to continue imposing on the president de iure was that any agreement should have as an "indeclinable basis" the acceptance of the Plan de Tuxtepec. Because of this condition, the negotiations failed, since everything that departed from the Constitution of 1857 would be rejected by Iglesias.
The breakdown of the negotiations left arms as the last means of action, so the military campaign was maintained until January 1877. The war came to an end with the betrayal of the military forces in the port of Mazatlán, which ended up surrendering the city to Porfirio Díaz, leaving Iglesias with no possibility of reorganizing his forces, who involuntarily had to go into exile to safeguard his integrity.
Undoubtedly, Porfirio Diaz's victory meant a great setback of the civil political stage that the Mexican nation had begun to live in the nineteenth century. This stage indeed presented some problems, such as the question of reelection, but the bayonet was not the means to solve these tensions. Very soon the government of General Diaz, established through the fortune of military victory, forgot one of its foundations outlined in the Plan of Tuxtepec, which was the issue of "no reelection", to give way to a dictatorship that allowed him to be reelected seven times.