The war occurred in 1846 and lasted through 1848. The war was about a border dispute between America and Mexico. America wanted New Mexico and California and a few other states, but Mexico refused to give it to them. So they started a war over it.
America felt that they needed the land from Mexico. Mexico denied them the land so America stood up to them and fought for it. Mexico didn’t want to give up the land to them, because they needed the land. It would benefit America if they won the war, they would get more land that has resources that they need.
Texas had already gotten independence. They had gained independence from Mexico during the Texas Revolution. And Mexico threatened America that they would go to war if they tried to annex Texas. Mexico thought that even though there was a Treaties of Velasco, that claimed that they had land up to the Rio Grande, the border of Texas was not officially there. So instead Polk just focused on westward expansion. I think that this is a smart idea because they could always annex Texas later.
They wanted to achieve Manifest Destiny. Manifest Destiny is expanding the U.S from that Atlantic Ocean to the Pacific Ocean. American forces quickly took over New Mexico and California, and then they started to invade Northeastern Mexico and Northwest Mexico. American minister in Mexico thought it would be good to cede California to settle debts.
The American people supported the Mexican American war because they felt it was necessary for them to have the land from Mexico. Americans had a border dispute between Mexico because Texas had become independent. So then New Mexico and California wanted to join the United States, and Mexico