The Presidential election of 1800 was a very important one. Before this time, the electors of the electoral college were not elected along party lines, and did not vote upon party lines. They actually voted for who they thought was the best person for the job (I am not making this up, as impossible as this concept seems nowadays.) Obviously, such an honor system couldn't last long, even back then. So around the time of 1800 the then two major parties (Federalists and Democratic-Republicans) had gotten groups of electors in each state who had pledged to vote for them if elected.
The Federalist candidates were incumbent President John Adams, and Charles Pickney, running against Democratic-Republicans Thomas Jefferson and Aaron Burr. At this time, the election did not work as it does now. While Pickney and Burr were informally running for vice-president, all four of them were on the ballot for the presidency. Whoever got the highest number of electoral votes (there was no "magic number" like there is now) won the presidency, and second place was stuck with vice-presidency, even if they were from different parties.
This election probably would have gone fine if a particular wrench by the name of Alexander Hamilton had not been thrown into it (or rather he threw himself into it). Hamilton was a prominent Federalist leader, but he hated John Adams, with a passion. He hated him so much, that he wrote and distributed a ten page pamphlet titled The Public Conduct and Character of John Adams that basically informed the public that Adams was an idiot who should not be elected. Hamilton also hated Burr and Jefferson, although he hated Burr more. So with only one person left he didn't hate, he urged Federalist voters to elect Charles Pickney come the first Tuesday after the first Monday in November.
Pickney unfortunately was from Charleston, South Carolina, which was one of very few trade/industry based cities in the south. But Federalists were by principal, against southerners, because they were almost all northern business owners/merchants, and southerners were almost all Democratic-Republican farmers. So come election day, all the Federalists voted for New York native Aaron Burr. Jefferson and Burr both tied at 73 electoral votes, and the decision of who would win fell upon the House of Representatives (as per the Constitution.)
Now, the original plan had called for Jefferson to become President, and Aaron Burr to be vice-president, and if there was a tie, Burr would step down. When Burr realized there actually was a tie, he did not step down, and the House voted 35 times to no avail. Finally, Hamilton came back on scene, and convinced a state to change their vote to Jefferson (whom he considered the lesser of two evils) on the 36th vote and so Jefferson won the presidency.
Burr was not at all happy with this, and so he immediately resigned from the vice-presidency, and soon became governor of New York, and eventually killed Hamilton in a pistol duel. Meanwhile, Congress realized this problem had to end, and the 12th Amendment was passed, which separated the presidential and vice-presidential ballots to what they are today.