Born on May 31, 1819, Walt Whitman was the second son of Walter Whitman, a housebuilder, and Louisa Van Velsor. The family, which consisted of nine children, lived in West Hills, Long Island and Brooklyn in the 1820s and 1830s. At the age of twelve Whitman quit school to learn the printer's trade, and fell in love with the written word. Largely self-taught, he read voraciously, becoming acquainted with the works of Homer, Dante, Shakespeare, and the Bible. Whitman worked as a printer in New York City until a devastating fire in the printing district demolished the industry. In 1836, at the age of 17, he began his career as teacher in the one-room school houses of Long Island. He continued to teach until 1841, when he turned to journalism as a full-time career.

Whitman moved to Manhattan where he worked in the printing office of Park Benjamin's popular New World. During this time he began placing poems and prose in the influential Democratic Review. By 1842, Benjamin was soliciting a novel from Whitman for his magazine's popular "Books for the People" series. In November of that year Whitman's first separately published work, Franklin Evans; or, The Inebriate: A Tale of the Times appeared. Advertisements hailed Whitman as "one of the best Novelists in this country." The temperance novel was so contrived and melodramatic, however, that, in later life, Whitman seemed embarrassed by it, going so far as to tell Horace Traubel that it had been written under the influence of alcohol. Ironically, it was Whitman's best selling work during his lifetime.

He founded a weekly newspaper, the Long-Islander, and later edited a number of Brooklyn and New York papers. In 1848, Whitman left the Brooklyn Daily Eagle to become editor of the New Orleans Crescent. It was in New Orleans that he experienced at first hand the viciousness of slavery in the slave markets of that city.

On his return to Brooklyn in the fall of 1848, he founded a "free soil" newspaper, the Brooklyn Freeman, and continued to develop the unique style of poetry that later so astonished Ralph Waldo Emerson. After resigning the editorship a year later, Whitman wrote for the New York Sunday Dispatch before briefly assuming the editorship of the New York Daily News. By 1851 he had suspended his formal relationship with journalism, contributing only occasional articles to various papers for the next few years while working as a carpenter in Brooklyn.

In 1855, Whitman took out a copyright on the first edition of Leaves of Grass, which consisted of twelve untitled poems and a preface. He published the volume himself, and sent a copy to Emerson in July of 1855. Whitman released a second edition of the book in 1856, containing thirty-three poems, and a forty-two-page appendix entitled "Leaves Droppings" of first edition reviews and a long open letter by Whitman in response. The focal point of "Leaves Droppings" is a laudatory letter of thanks from Ralph Waldo Emerson which Whitman received in return for a complimentary copy of the first edition. Whitman used the letter as an endorsement without Emerson's permission, going so far as to quote it on the spine of this edition. Emerson's immediate reaction to Whitman's promotional tactics is unknown, but, considering the book's stormy public reception, it is unlikely that he would have been pleased. During his subsequent career, Whitman continued to refine the volume, publishing several more editions of the book.

At the outbreak of the Civil War, Whitman vowed to live a "purged" and "cleansed" life. He wrote freelance journalism and visited the wounded at New York-area hospitals. He then traveled to Washington, D.C. in December 1862 to care for his brother who had been wounded in the war at the Battle of Fredericksburg. Overcome by the suffering of the many wounded in Washington, Whitman volunteered his afternoons nursing Union casualties in the area's many hospitals. Whitman stayed in the city for eleven years. First working as copyist for the army's paymaster, he then took a job as a clerk for the Department of the Interior, which ended when the Secretary of the Interior, James Harlan, discovered that Whitman was the author of Leaves of Grass, which Harlan found offensive. Harlan fired the poet. When asked to reinstate Whitman by the Attorney General, absolutely refused to give the poet his position back. Though Whitman would eventually be transfered to the Attorney General's office, the obscenity issue continued to surround Leaves of Grass.

Whitman struggled to support himself through most of his life. In Washington he lived on a clerk's salary and modest royalties, and spent any excess money, including gifts from friends, to buy supplies for the patients he nursed. He had also been sending money to his widowed mother and an invalid brother. From time to time writers both in the states and in England sent him "purses" of money so that he could get by.

In the early 1870s, Whitman settled in Camden, where he had come to visit his dying mother at his brother's house. However, after suffering a stroke, Whitman found it impossible to return to Washington.

Between 1876 and 1881, the aging Whitman spent much of his time traveling. His first journeys took him to a friend's farm in Pennsylvania where he continued recuperating from his stroke. Once his health had returned, though, his travels expanded, visiting upstate New York (1878), Colorado (1879), and Ontario (1880).

He stayed with his brother until the 1882 publication of Leaves of Grass gave Whitman enough money to buy a home in Camden, New Jersey. In the simple two-story clapboard house, Whitman spent his declining years working on additions and revisions to a new edition of the book and preparing his final volume of poems and prose, Good-Bye, My Fancy (1891). After his death on March 26, 1892, Whitman was buried in a tomb he designed and had built on a lot in Harleigh Cemetery.