在1860年代,法国在墨西哥发生内战的时候控制了墨西哥,但他并没有完全控制就被推翻了,在1867年,恢复民主制度,华雷斯城〈Juárez〉竞选连任成功,继续推行他的改革。在1871年,他当选第二次,他的反对党自由党,他们认为选举过程不民主。华雷斯城去世一年后,米格尔德特哈达继任〈Miguel Lerdo de Tejada〉。
In the 1860s, the country again underwent a military occupation, this time by France, establishing the Habsburg Archduke Ferdinand Maximilian of Austria on the throne of Mexico as Emperor Maximilian I of Mexico, with support from the Roman Catholic clergy and conservative elements of the upper class as well as some indigenous communities. Although the French, then considered one of the most efficient armies of the world, suffered an initial defeat in the Battle of Puebla on May 5, 1862 (now commemorated as the Cinco de Mayo holiday) they eventually defeated the Mexican government forces and set the couple upon the throne.
The Mexican monarchy set up its government in the Capital of Mexico City and used the National Palace as their government seat. The Emperor's consort, born a Belgian princess, was Empress Carlota of Mexico, a cousin of Queen Victoria of the United Kingdom. The Imperial couple chose as their home Chapultepec Castle, and later adopted two grandchildren of the first Mexican Emperor, Augustin I. The Imperial couple noticed how the people of Mexico were treated, especially the Indians, and wanted to ensure their human rights. They were interested in a Mexico for the Mexicans, and did not share the views of Napoleon III, who was interested in exploiting the rich mines in the north-west of the country.
Emperor Maximilian I favored the establishment of a limited monarchy sharing powers with a democratically elected congress. This was too liberal to please Mexico's Conservatives, while the liberals refused to accept a monarch, leaving Maximilian with few enthusiastic allies within Mexico. President Benito Juárez kept the federal government functioning during the French intervention that put Maximilian in power.
In mid-1867, following repeated losses in battle to the Republican Army and ever decreasing support by Napoleon III, Maximilian was captured and executed by Juárez's soldiers, along with his last loyal generals, Mejia and Miramon in Querétaro. From then on, Juárez remained in office until his death from heart failure in 1872.
Restoration of the Republic
In 1867, the republic was restored and Juárez was reelected, continuing to implement his reforms. In 1871 he was elected a second time, much to the dismay of his opponents within the liberal party, who considered reelection to be something undemocratic. Juárez died one year later and was succeeded by Sebastián Lerdo de Tejada.