Mexico was not a colony of France. However, between 1861 and 1867, French forces invaded Mexico, with the goal of creating a puppet state thus allowing them to have a foothold in the Americas, and help the Confederacy during the American Civil War (1861-1865). However, this Second Mexican Empire didn't last long: after France got the upper hand against Mexico in 1863, Mexicans resorted to a guerilla war. When France saw the need to recall its troops due to an imminent conflict against Prussia, and Union forces won over the Confederacy, Mexicans were able to defeat the French on June 21, 1867.