In 1836, Texas, a republic located southwest of the Louisiana Territory of the United States, gained its independence from Mexico. Because Texas allowed slavery, the United States was reluctant to admit Texas into the Union. After his election, James Polk immediately began proceedings for the annexation of Texas, despite a warning from Mexico.

The Mexican government encouraged raids along the border. Mexico also warned the United States government that it would go to war if Texas was annexed.

In 1844, James Polk was elected President of the United States. Polk was in favor of expanding the United States by purchasing Mexican land southwest of the United States. When he was unable to make the purchase, he moved U.S. troops into disputed land between the Rio Grande and the Nueces River. Both Mexico and Texas laid claim to this area. (Click on the yellow star to see a map of this area.)