From Texas Standard:
The document that sealed Texas' entry into the United States is the Treaty of Guadalupe Hidalgo. Mexican officials were forced to sign it in 1848, at the close of the bloody Mexican-American War. The treaty let the United States annex most of Mexico's historic territory and pay $15 million for the land in installments. At least half of Mexico’s regional territory went to the U.S. – what now is Texas, Arizona, New Mexico and California. Both countries would look much different if it were never signed, or if it were to be nullified.