The Republican Party, led by Abraham Lincoln, won the 1860 presidential election. Southerners were outraged by the election of Lincoln, who opposed slavery in territories and new states. After the election seven Southern states seceded and declared their independence from the Union. They formed the Confederate States of America, even before Lincoln became president on March 4, 1861. The outgoing U.S. president, James Buchanan, said this was against the law, but did nothing to stop them. Lincoln and his Republican party treated this secession as a rebellion.