December, 1846 - August, 1848
Since 1839 the Yucatan peninsula had been embroiled in an on-again, off-again struggle against Mexico City, demanding greater regional autonomy. In December, 1846, the region declared its independence from the Mexican republic and adopted a policy of neutrality in the war with the United States.
The following year a bloody caste war erupted between Maya Indians and creole landowners. After more than a year of fierce fighting that would claim the lives of almost half the peninsula's population, the Mayan rebels managed to seize most of the Yucatan. By the spring of 1848, only the walled cities of Campeche and Mérida remained under the control of white elites.
Desperate for foreign assistance, the Yucatan government appealed to the U.S. government to extend sovereignty over the region. Polk had hitherto shown little interest in Yucatan affairs. However, when Polk learned that the Yucatán might appeal to European powers if American aid was not forthcoming , the matter suddenly became one of grave concern. In Congress, expansionist Democrats called for the temporary occupation of the region, but the Whigs denounced the scheme as a violation of the Treaty of Guadalupe Hidalgo. In the end Yucatecos turned to the government in Mexico City, which agreed to join the fight against the Indians. In exchange, Yucatán rejoined the Mexican republic in August, 1848.