The American Civil War, also known as the War Between the States, or simply the Civil War in the United States, was a civil war fought from 1861 to 1865 in the United States after seven Southern slave states declared their secession and formed the Confederate States of America (the "Confederacy" or the "South"). The states that remained in the Union were known as the "Union" or the "North". The war had its origin in the fractious issue of slavery, especially the extension of slavery into the western territories. Foreign powers did not intervene. After four years of bloody combat that left over 600,000 soldiers dead and destroyed much of the South's infrastructure, the Confederacy collapsed, slavery was abolished, and the difficult Reconstruction process of restoring national unity and guaranteeing rights to the freed slaves began.
In the 1860 presidential election, Republicans, led by Abraham Lincoln, opposed the expansion of slavery into United States' territories. Lincoln won, but before his inauguration on March 4, 1861, seven slave states with cotton-based economies formed the Confederacy. Outgoing Democratic President James Buchanan and the incoming Republicans rejected secession as illegal. Lincoln's inaugural address declared his administration would not initiate civil war. Eight remaining slave states continued to reject calls for secession. Confederate forces seized numerous federal forts within territory claimed by the Confederacy. A peace conference failed to find a compromise, and both sides prepared for war. The Confederates assumed that European countries were so dependent on "King Cotton" that they would intervene; none did and none recognized the new Confederate States of America.
Hostilities began on April 12, 1861, when Confederate forces fired upon Fort Sumter, a key fort held by Union troops in South Carolina. Lincoln called for each state to provide troops to retake the fort; consequently, four more slave states joined the Confederacy, bringing their total to eleven. The Union soon controlled the border states and established a naval blockade that crippled the southern economy. The Eastern Theater was inconclusive in 1861–62. The autumn 1862 Confederate campaign into Maryland (a Union state) ended with Confederate retreat at the Battle of Antietam, dissuading British intervention. Lincoln issued the Emancipation Proclamation, which made ending slavery a war goal. To the west, by summer 1862 the Union destroyed the Confederate river navy, then much of their western armies, and the Union siege of Vicksburg split the Confederacy in two at the Mississippi River. In 1863, Robert E. Lee's Confederate incursion north ended at the Battle of Gettysburg. Western successes led to Ulysses S. Grant's command of all Union armies in 1864. In the Western Theater, William T. Sherman drove east to capture Atlanta and marched to the sea, destroying Confederate infrastructure along the way. The Union marshaled the resources and manpower to attack the Confederacy from all directions, and could afford to fight battles of attrition through the Overland Campaign towards Richmond, the Confederate capital. The defending Confederate army failed, leading to Lee's surrender to Grant at Appomattox Court House on April 9, 1865. All Confederate generals surrendered by that summer.