Barack Obama was elected President of the United States in 2008, then re-elected in 2012. Prior to these elections, he served as a state senator and then a U.S. Senator for Illinois.
In 1996, Barack Obama ran for state senator representing Illinois' heavily Democratic 13th District. He won unopposed after invalidating all four of his opponents' petitions to run and served until 2004, at which point he chose to run for a U.S. Senate seat. He won this election with 70 percent of the vote when both his major primary and general election opponents had to withdraw due to well-publicized sex scandals. While still a U.S. Senator, Obama ran for the Democratic presidential nomination in 2008, winning both the nomination and the general election to become President of the United States.