By JULIET MACUR and LYNN ZINSER
COPENHAGEN — The Olympics were awarded to a South American city for the first time when the International Olympic Committee on Friday voted for Rio de Janeiro to be host of the 2016 Games.
Rio de Janeiro was the winner over Madrid in the final round of voting. The committee delivered an unexpectedly early knockout blow to Chicago, which was eliminated in the first round. Tokyo was ousted in the second.
Jacques Rogge, the president of the committee, made the announcement, sending crowds in Rio de Janeiro into celebration.
Tens of thousands of people began partying early in Rio on the Copacabana beach. Musicians played samba music from a main stage flanked by large screens, as people danced, held towering cones of cotton candy and showed off the national colors of Brazil by donning yellow-and-green wigs or yellow-and-green bikinis. A beach ball bounced above the crowd, marked with the words, “It’s Rio’s time.”
The scene was different earlier in Chicago as throngs in Daley Plaza gasped in disappointment when Rogge announced that Chicago was out. It was a surprisingly early exit, especially after President Obama’s whirlwind trip to boost the bid of his adopted city. Mr. Obama was the first American president to make an in-person appeal for a bid city and the first lady, Michelle Obama, had also come here this week to lobby I.O.C. members for votes.
Chicago’s bid leaders had worked for nearly four years and spent close to $50 million to bring the Summer Olympics to the United States for the first time in 20 years. Chicago had been considered among Olympic insiders as a favorite to win the Games, along with Rio.
Instead, the I.O.C. delivered a crushing blow to American hopes for the second straight time. New York’s bid was eliminated in the second round of voting for the 2012 Olympics.
United States Olympic Committee leaders appeared stunned by the news and had no comment as they left the voting hall. Mr. Obama was flying back to Washington at the time of the vote.
Brazilian President Luiz Inácio Lula da Silva had led Rio’s emotional appeal to win the Games and the urge to make history tugged at the I.O.C., which voted it the winner over Madrid.
Former I.O.C. president Juan Antonio Samaranch of Spain, who is 89, had made a passionate and personal appeal for Madrid in its presentation, including a tug at the members’ heartstrings.
“Dear colleagues, I know I’m very near the end of my time, I’m 89 years old,” he said. “I ask you to consider granting my country the honor and also the duty to organize the Games and Paralympic Games in 2016.”
To win, Rio’s bid leaders had to overcome sentiment for Samaranch and concerns about security in the teeming Brazilian city. There were also concerns that the country would already be overextended in hosting the 2014 World Cup.
Chicago had plenty of its own hurdles, with many issues idling in what is often a strained relationship between the Euro-centric I.O.C. and Olympic efforts in the United States. Chicago hoped to do better than New York fared in the last bidding process, but recent turnover at the United States Olympic Committee and a now-scrapped idea to start an American Olympic network over I.O.C. objections did not help Chicago’s chances.
That made Mr. and Mrs. Obama’s visit critical. Spain’s King Juan Carlos and Japanese Prime Minister Yukio Hatoyama also came to work on behalf of Madrid and Tokyo.
Voting was done electronically and by secret ballot. It was done in rounds until one city earned a majority of votes. I.O.C. members from the countries of the bid cities do not vote while those cities are still in contention. Chicago received the fewest votes in the first round, eliminating it and that fate befell Tokyo in the second round.
United States Olympic Committee leaders appeared stunned by the news and had no comment as they left the voting hall. Mr. Obama was flying back to Washington at the time of the vote.
Teams from the four candidate cities delivered their final presentations to the 104-member I.O.C. and answered every lingering question about the strengths and weaknesses of their bids earlier Friday.
The 10-person Chicago bid team, led by the president and Mrs. Obama, put on a presentation heavy on emotion and visual images without getting too deep into he details of the bid.
“To host athletes and visitors from every corner of the globe is a high honor and a great responsibility,” Mr. Obama whose Chicago home is a short walk from the prospective Olympic Stadium. “And America is ready and eager to assume that sacred trust.”
In the official question-and-answer session following the Chicago presentation, Syed Shahid Ali, an I.O.C. member from Pakistan, asked the toughest question. He wondered how smooth it would be for foreigners to enter the United States for the Games because doing so can sometimes, he said, be “a rather harrowing experience.”
Mrs. Obama tapped the bid leader Patrick G. Ryan, so Mr. Obama could field that question.
“One of the legacies I want to see is a reminder that America at its best is open to the world,” he said, before adding that the White House and State Department would make sure that all visitors would feel welcome.
Tokyo went next and tried to overcome impressions conveyed by I.O.C. evaluations that its bid was lacking. The bid team emphasized to the committee how environmentally friendly its plans are and the positive impact an Olympics would have on the youth of Japan.
“A lot of I.O.C. members suggested that we needed more passion and emotion,” bid leader Dr. Ichiro Kono said afterward. “We wanted to show that.”
Rio de Janeiro followed Tokyo and Da Silva gave an impassioned speech to the membership about South America’s quest for the Games. He said that of the top 10 economic powers in the world, Brazil is the only one not to host an Olympics.
“For the others it would be just one more Games, for us it would be an unparalleled opportunity,” he said. “It would send a message the Olympic Games belong to all people, all continents and all humanity.
He added, “Give us this chance and you will not regret it, be sure.”
Rio leaders worked to dispel worries about crime.
“We know that some of you have questions about security,” Rio de Janeiro state Governor Sergio Cabral said, as he addressed the committee. “Changes have been made, happily as a result of sport.”
Cabral pointed out that at the 2007 Pan American Games, which were held in Rio de Janeiro, “saw no incidents large or small.”
Madrid gave its presentation last, as Spain made is fourth consecutive pitch to host an Olympics. Madrid was voted out of the competition for the 2012 Games in the third round after gathering the most votes in the previous round.
Presenters focused on the mantra, “Sport makes us equal. It makes us better,” and emphasized that Madrid enjoys more support among its residents than competing cities. In an opinion poll commissioned by the I.O.C. for the last technical evaluation, the Games had 85 percent support in Madrid and 86 percent nationally.
“Our candidacy is reliable because it is united politically and united with the feelings of the population and because it has shown that it could learn and improve,” Spanish prime minister José Luis Rodríguez Zapatero said when addressing the I.O.C. members.
After Madrid finished, the I.O.C. began the voting. Chicago was eliminated because it received the fewest number of votes in the first round, the fate the befell Tokyo in the second. Voting was done electronically and secretly, with sitting out until their city was eliminated. (The United States has two I.O.C. members.)
Chicago spent nearly $50 million preparing its bid and is trying to bring the Summer Games to the United States for the first time since the 1996 Atlanta Olympics. The last time a United States city hosted any Olympics was the Salt Lake City Winter Games in 2002.
Smiling and waving as he left the convention center to fly home, Mr. Obama said, “The only thing I’m upset about is that they arranged for me to follow Michelle. That’s always bad.”
The United States Olympic Committee chairman, Larry Probst, Chicago Mayor Richard M. Daley and two athletes — Olympic champion decathlete Bryan Clay and former Paralympian Linda Mastandrea — also spoke during the 45-minute presentation that was designed not to be too flashy.
“Our intent was to demonstrate to them we will be good partners and that we are people they could trust,” Doug Arnot, director of sports and operations for Chicago 2016.
The delegation’s presentation started with a video montage of Chicago, including bikini-wearing volleyball players on Lake Michigan beaches. The song, “Sweet Home Chicago” played in the background. “It made me miss home,” Mr. Obama said.
The last time around, in the competition to host the 2012 Games, London beat Paris by the slim margin of 54-50. Every bid team brought distinguished leaders, including King Juan Carlos for Spain and Prime Minister Yukio Hatoyama for Japan.
Dozens of Olympians have flooded the city to lobby for their city’s cause, including the Brazilian soccer legend Pelé.
With Mrs. Obama and Oprah Winfrey headlining the delegation, the Chicago team had been reminding I.O.C. members of their Olympic plan, which would have put the Games along the shoreline of Lake Michigan and in century-old city parks, with Chicago’s dramatic skyline as the backdrop. The Chicago City Council voted 49-0 to cover any financial shortfalls, which was a first for a U.S. bid.
“Some of what the I.O.C. considers has nothing to do with the strength of the bids themselves,” said Frank Lavin, the former U.S. ambassador to Singapore, who worked on New York City’s failed bid to host the 2012 Games.
“A lot of it is political and that encompasses different levels: international politics, personalities, internal I.O.C. politics,” he said.