Mexicans had just finished a civil war that went from 1858 to 1860. President Benito Juarez had just been in office for six months in July of 1861. Leaders of the failed opposition forces had fled to France. They had emptied Mexico’s treasury as they left, and the incoming Juarez government was all but bankrupt and simply could not pay its international debts. At about the same time, rebel forces from the south defeated the northern union forces in the bloody Battle of Bull run. In Paris, France’s Emperor Napoleon III had been looking for an opportunity to halt U.S. expansion and reestablish French influence in the western hemisphere. France had lost its last major stronghold by selling New Orleans and the entire Louisiana Territory to the United States in 1803. Napoleon had hesitated to take on the United States directly, but now the news of the Civil War changed everything.
French, British and Spanish troops landed in the port of Veracruz and seized the customs house, but it soon became clear that the French had more in mind than simply the collection of debts. For the next five years, Mexicans struggled to get the French to leave, but the Mexicans had mobility on their side. They could live off the land, sleep on the ground, and cover three or four times the distance the French could march on any given day. One tactical error that Napoleon III made was to send Austrian Archduke Ferdinand Maximilian to rule Mexico as as emperor. Maximilian turned out to be unfit for the job. The Confederates, meanwhile, had discovered that the French - under the guise of "helping" the south - wanted to take Texas and put it back into Mexico under French control. The political and military wrangling went on until July of 1867, when the French army had finally left and Benito Juarez returned to reclaim his country in Mexico City.