On October 20, 1818, in order to improve relations in the wake of the War of 1812, Great Britain and the United States agree to peaceful coexistence in the Pacific Northwest by signing the Convention of 1818 (also known as the Treaty of Joint Occupation) in London.
Article 3 concerns the Pacific Northwest and reads:
"It is agreed, that any Country that may be claimed by either Party on the North West Coast of America, Westward of the Stony Mountains, shall, together with its Harbours, Bays, and Creeks, and the Navigation of all Rivers within the same, be free and open, for the term of ten Years from the date of the Signature of the present Convention, to the Vessels, Citizens, and Subjects of the Two Powers: it being well understood, that this Agreement is not to be construed to the Prejudice of any Claim, which either of the Two High Contracting Parties may have to any part of the said Country, nor shall it be taken to affect the Claims of any other Power or State to any part of the said Country; the only Object of The High Contracting Parties, in that respect, being to prevent disputes and differences amongst Themselves."
The treaty restrained both nations from seeking unfair advantage through accelerated settlement of the area, which was then dominated by the Hudson's Bay Company.
It was amended in 1827, but the United States took a more aggressive posture after the Wilkes expedition of 1841. Rebellious American settlers in Oregon declared a provisional government in 1843, and some American politicians, using the slogan the slogan "Fifty-four Forty or Fight," argued that the American boundary should extend all the way to latitude 54-40, then the southern boundary of Russian Alaska.
The British disagreed, and America chose not to fight: In the 1846 Treaty of Oregon, the two nations compromised by establishing the 49th parallel, already the U.S.-Canada border east of the Rockies, as the boundary in the mainland Pacific Northwest.