In 1877, Democrat Samuel J. Tilden was awarded the presidency of the United States by an 8-7 vote of an electoral commission established to resolve the disputed 1876 election.
Tilden won after the defection of a single Republican commission member forced the commission to evenly divide the disputed electoral votes of three Southern states rather than, as the other Republican members had wanted, awarding them all to GOP contender Rutherford B. Hayes.
Had the dissident member voted with his fellow Republicans, Hayes would have won, by 185 electoral votes to Tilden's 184.
The "back-room" character of this decision lent force to a movement to abolish the Electoral College, and in 1901, the Sixteenth Amendment to the U.S. Constitution would do exactly that, establishing direct election of the president. Ironically, U.S. senators would not be directly elected until the passage of the Seventeenth Amendment in 1913; until that time, they would continue to be chosen by state legislatures.