James Hamilton was born in Charleston, South Carolina, on May 8, 1786, the son of Major James and Elizabeth Hamilton. Hamilton studied law in Charleston and was admitted to the bar in 1810. He served as Secretary to South Carolina Governor Henry Middleton until the War of 1812, when he volunteered to fight.
After the War of 1812, Hamilton became increasingly involved in South Carolina politics. He served in the lower house of the state legislature from 1819 to 1822. Hamilton first gained national recognition for his role in the suppression of the Denmark Vesey slave revolt in 1822. He represented South Carolina in the U.S. Congress from 1822 to 1829. While in Washington, D.C., Hamilton was very active in affairs of national government. He became well known as an advocate of state's rights.
Elected governor of South Carolina in 1830, Hamilton organized the movement that led to the Nullification Ordinance of 1832. After leaving the governorship, he served in the South Carolina state senate from 1834 to 1836 and served as a diplomatic agent for the Republic of Texas from 1839 to 1842. Following a series of business reverses, Hamilton went deeply into debt and lost much of his public reputation by the 1850s. He drowned in the Gulf of Mexico in 1857.