Okay, so a long time ago, Mexico used to belong to Spain. But then, Mexico said "adios" to Spain and became its own independent country. Later on, Spain decided it wanted Mexico back and tried to take it over again.
The Spanish sent a big army to Mexico, called the Armada, to try to reconquer the country. They thought it would be easy to just take over again, but they were wrong. The people of Mexico didn't want to go back to being ruled by Spain and fought back.
The Mexicans had a really good leader named Miguel Hidalgo who rallied people to join his army and take on the Spanish. They had some big battles and even though the Mexicans were outnumbered, they were able to win some of them.
But things didn't go well for Hidalgo and his army, and eventually the Spanish were able to defeat them. But even though the Spanish won the war, they couldn't really control Mexico like they used to. The people of Mexico were still very proud and independent, and Spain wasn't able to reconquer Mexico for good.