Daniel Webster had been in the U.S. Senate in 1850 during the debates over slavery in the new territories gained from Mexico following the Mexican-American War. After he assumed the office of the secretary of state for a second time, he continued to work for the passage of what would become known as the Compromise of 1850. His interest in foreign relations focused on trade. In the Pacific, the expedition of Commodore Matthew C. Perry opened Japan to trade, and Webster also negotiated trade agreements with Latin American nations, at the same time discouraging British influence.
Webster became ill in 1852 and died at his farm in Massachusetts while still serving as secretary of state.