During James Monroe's presidency from 1817 to 1825, known as the Era of Good Feelings, the US economy grew and political differences diminished. The Rush-Bagot Agreement limited naval forces on the Great Lakes, while the Adams-Onis Treaty settled border disputes with Spain and allowed Florida to become a US territory. The Missouri Compromise admitted Missouri to the Union as a slave state and Maine as a free state, while prohibiting slavery in the Louisiana Territory north of Missouri. Monroe issued the Monroe Doctrine opposing European colonization in the Americas.