 Before the creation of Montana Territory (1864–1889), areas within present-day Montana were part of the Oregon Territory (1848–1859), Washington Territory (1853–1863), Idaho Territory (1863–1864), and Dakota Territory (1861–1864).Montana became a United States territory (Montana Territory) on May 26, 1864.The first territorial capital was at Bannack.