In 1821, Mexico gained its independence from Spain. The Southwest came under Mexican control. This included New Mexico. Mexico allowed U.S. settlers to enter New Mexico. One of the traders opened the Santa Fe Trail in 1821. This trail linked Missouri with Sante Fe. Many people in the United States wanted to control the Southwest. They started the Mexican War. The United States won the war. New Mexico then became a U.S. territory. Thousands of U.S. settlers moved there.
Many of these settlers moved onto Apache and Navajo lands. Native Americans led raids against the settlers. U.S. troops fought the Native Americans. In the 1860's troops forced the Navajo and Apache to leave their homeland. They moved the Native Americans to a reservation on the Pecos River. In 1868, the Navajo returned to northwestern New Mexico. The Apache fought U.S. control for 20 years. They were lead by the Apache leader Geronimo. He finally surrendered in 1886.
In the 1870's railroads opened and this brought thousands of settlers. Gold and silver mining grew and Texas cattle ranchers moved into the southeastern part of the territory.
On January 6, 1912, New Mexico became the 47th state. Sante Fe was named the state capital. It is the oldest capital city in the United States.
Visit Explore the States for more information on the history of New Mexico.