In 1848, the Oregon Territory, composed of present-day Washington, Oregon, and Idaho as well as parts of Montana and Wyoming, was established. Washington Territory, which included Washington and pieces of Idaho and Montana, was formed from Oregon Territory in 1853. In 1872, An arbitration process settled the boundary dispute from the Pig War and established the US–Canada border through the San Juan Islands and Gulf Islands.