Francis Scott Key (August 1, 1779 – January 11, 1843) was an American lawyer, author, and amateur poet from Frederick, Maryland who is best known for writing a poem which later became the lyrics for the United States' national anthem, "The Star-Spangled Banner".
During the War of 1812, Key observed the British bombardment of Fort McHenry in Maryland in 1814. Key was inspired upon viewing the American flag still flying over the fort at dawn, and wrote the poem "Defence of Fort M'Henry", which was published a week later. The poem was adapted to the tune of the popular song "To Anacreon in Heaven." The song with Key's lyrics became known as "The Star-Spangled Banner," and slowly gained in popularity as an unofficial anthem over the years, finally achieving official status a century later under President Woodrow Wilson as the United States national anthem.
Key was a lawyer in Maryland and Washington D.C. for four decades, and worked on important cases like the Burr conspiracy trial, and argued numerous times before the U.S. Supreme Court. Nominated for U.S. attorney by President Andrew Jackson, he served from 1833 to 1841.
Key owned slaves from 1800 but freed them in the 1830s, paying one ex-slave as his farm foreman. Key publicly criticized slavery and gave free legal representation to some slaves seeking freedom, but also represented owners of runaway slaves as well. Representing both slaves and slave owners is emblematic of his complex relationship with slavery. As District Attorney, Key suppressed abolitionists and didn't support an immediate end to slavery. Instead he supported "recolonizing Africa" which meant sending freed slaves back to Africa.
Key was a devout Episcopalian. He was also an author of poetry, and often wrote on religious themes. It has been speculated that the U.S. motto "In God We Trust" was adapted from a line in the fourth stanza of the "Star-Spangled Banner".