Story highlights

The 35-year-old becomes the sport's most decorated sailor with a haul of five medals

Sweden's Max Salminen and Fredrik Loof win the Star gold medal

Britain's Ben Ainslie became the most decorated Olympic sailor in history with his fourth successive victory -- and then declared it was his last involvement at the Games.

The 35-year-old came ninth in Sunday's medal race but, crucially, finished ahead of his main rival for the gold medal -- Denmark's Jonas Hogh-Christensen.

Pieter-Jan Postma, from the Netherlands, had an opportunity to leapfrog both Ainslie and Hogh-Christensen but a poor last stretch saw him finish fourth overall. France's Jonathan Lobert took the bronze.

It marked a fairytale ending for Ainslie, who had trailed Hogh-Christensen through the majority of the competition, only to take gold at the last in front of a vociferous crowd at Weymouth, on England's south coast.

But he said he was unlikely to defend his crown for a fifth time at the 2016 Olympics in Rio.

"It's times like this you are supposed to come out with something clever but I can't think of anything," Ainslie told the host broadcaster, after eclipsing Denmark's Paul Elvstrom as the sport's best.

"I am speechless. I am just so glad for everyone who has supported me over the last four years. It has been an amazing Olympics.

Day 9: The best photos of the Olympics 80 photos

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – With a time of 9.63 seconds, Usain Bolt of Jamaica wins the gold in the men's 100-meter final on Sunday, August 5. Check out Day 8 of competition from Saturday, August 4. The Games ran through August 12.

Hide Caption

1 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Kibwe Johnson of the United States competes in the men's hammer throw final.

Hide Caption

2 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – No. 4 Adriana Pinto is thrown into the air by teammates to honor her final game with the Brazil National Team after the women's basketball preliminary round match against Great Britain.

Day 9: The best photos of the Olympics – Silver medalist Mahiedine Mekhissi-Benabbad of France celebrates after the men's 3,000-meter steeplechase final.

Hide Caption

5 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Roman Vlasov of Russia exults after he defeats Arsen Julfalakyan of Armenia in their men's Greco-Roman 74-kilogram wrestling gold medal bout.

Hide Caption

6 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Cassidy Krug of the United States swims after her dive in the women's 3-meter springboard diving final.

Hide Caption

7 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Asafa Powell of Jamaica and Justin Gatlin of the United States lead the pack in the men's 100-meter semifinal.

Hide Caption

8 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Xi Zhang of China, left, sets the ball for teammate Chen Xue during the women's beach volleyball quarterfinal match against Austria.

Hide Caption

9 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Andrea Baldini of Italy is joyous after defeating Kenta Chida of Japan to win the gold medal in the men's foil team fencing.

Hide Caption

10 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Aliaksandr Kikiniou of Belarus, in red, grapples with Emin Ahmadov of Azerbaijan in their men's Greco-Roman 74-kilogram wrestling bronze medal match.

Hide Caption

11 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Yamile Aldama of Great Britain reacts after completing her jump in the women's triple jump final.

Hide Caption

12 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Tania Cagnotto of Italy performs an acrobatic dive in the women's 3-meter springboard diving final.

Hide Caption

13 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Hamid Mohammad Soryan Reihanpour of Iran celebrates winning the gold medal in the men's Greco-Roman 55 kilogram wrestling bout.

Hide Caption

14 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Andy Murray of Great Britain walks off the court after defeating Roger Federer of Switzerland and winning the gold medal in the men's singles tennis competition.

Hide Caption

15 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Peter Modos of Hungary, top, wrestles with Arsen Eraliev of Kyrgyzstan, bottom, during the men's Greco-Roman 55-kilogram wrestling qualification.

Hide Caption

16 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Action from the star class medal race at Weymouth Harbour in Weymouth, England.

Hide Caption

17 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Yun Cai and Haifeng Fu of China revel in their victory against Mathias Boe and Carsten Mogensen of Denmark in the men's doubles badminton gold medal match.

Hide Caption

18 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Luisa Peters of the Cook Islands lifts during the women's 75-plus kilogram group A weightlifting event.

Hide Caption

19 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Crowds gather in Olympic Park on Day 9 to watch Andy Murray on the big screens win his gold medal in the men's singles tennis match.

Hide Caption

20 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Denmark's Lasse Norman Hansen crashes during the men's 15-kilometer scratch race cycling event at the London Velodrome.

Hide Caption

21 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Gold medalist Andy Murray of Great Britain and silver medalist Roger Federer of Switzerland acknowledge the fans during the medal ceremony for the men's singles tennis match. Murray defeated Federer in straight sets, 2-6, 1-6, 4-6.

Hide Caption

22 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Canadian forward Michelle Plouffe, center, struggles with Australian center Elizabeth Cambage for control of the ball during the women's preliminary round group B basketball match.

Hide Caption

23 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Cyril Tommasone of France performs his routine in the artistic gymnastics men's pommel horse final.

Hide Caption

24 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Germany's Sebastian Bachmann is treated by medical personnel after being injured during his bout with U.S. fencer Gerek Meinhardt during the men's foil team medal bronze match.

Hide Caption

25 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Elsabeth Black of Canada is consoled by a teammate after twisting her ankle in the artistic gymnastics women's vault final.

Hide Caption

26 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Jimmy Watkins, left, of the United States and Shane Perkins, right, of Australia fly around the track during the men's sprint quarterfinals cycling event.

Hide Caption

27 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Mingiyan Semenov, left, of Russia grapples with Spenser Thomas Mango of the United States during the men's Greco-Roman 55-kilogram wrestling qualification matches.

Hide Caption

28 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Marcel Marcilloux of France strikes Richard Kruse of Great Britain during the men's foil team fencing match.

Hide Caption

29 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Denmark's Lasse Norman Hansen experiences the thrill of victory after winning the gold medal in the men's omnium 1 kilometer time trial cycling event.

Hide Caption

30 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Peter Modos of Hungary jumps for joy after winning the men's Greco-Roman 55-kilogram wrestling bronze medal bout against Haakan Erik Nyblom of Denmark.

Hide Caption

31 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Eilidh Child of Great Britain clears a hurdle in the women's 400-meter hurdles round 1 heat.

Hide Caption

32 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – A tourist enjoys the view of giant Olympic rings floating in the River Thames opposite Parliament on Sunday, August 5, in London, England.

Hide Caption

33 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Great Britain's Andy Murray exults after defeating Switzerland's Roger Federer to win the gold medal in men's tennis singles at Wimbledon.

Hide Caption

34 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Serena and Venus Williams serve the ball to Andrea Hlavackova and Lucie Hradecka of the Czech Republic during the women's doubles final. The Williams sisters went on to win the gold medal, which they also won at the 2008 Olympics.

Hide Caption

35 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Wrapped in her nation's flag, Tiki Gelana of Ethiopia celebrates winning the women's marathon.

Hide Caption

36 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Despite the rain, two spectators eagerly await a view of runners in the women's marathon near St. Paul's Cathedral in London.

Hide Caption

37 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Spectators take photographs and shout encouragement to the runners in the women's marathon.

Hide Caption

38 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Ben Ainslie of Great Britain hoists the Union Jack and acknowledges the cheers from fans after winning the gold medal in the finn class medal race in Weymouth, England.

Hide Caption

39 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Kara Goucher, left, and Shalane Flanagan of the United States support each other after completing the women's marathon.

Hide Caption

40 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Mary Killman and Mariya Koroleva of the United States compete in the women's duets synchronized swimming technical routine.

Hide Caption

41 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Enrique Tomas Gonzalez Sepulveda of Chile soars above the floor during the artistic gymnastics men's floor exercise final.

Hide Caption

42 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Romania's Sandra Raluca Izbasa reacts after winning gold in the women's vault final of the artistic gymnastics event.

Hide Caption

43 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Supporters of Fredrik Loof and Max Salminen of Sweden celebrate as the sailors take overall victory following the men's star sailing medal race.

Hide Caption

44 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Kamal Bahamdan of Saudi Arabia riding Noblesse Des Tess jump over an obstacle in the second qualifier of individual jumping.

Hide Caption

45 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Montenegro's Bojana Popovic, left, vies with Russia's Liudmila Bodnieva, center, during a women's preliminary handball match.

Hide Caption

46 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Andy Murray of Great Britain serves the ball to Roger Federer of Switzerland during the men's singles tennis gold medal match. Murrary went on to win the match.

Hide Caption

47 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Ghana's Alberta Boatema Ampomah prepares her hands before competing in the women's 75-plus kilogram group A weightlifting event.

Hide Caption

48 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Seiya Kishikawa and Koki Niwa of Japan compose themselves during their men's team table tennis quarterfinal match against the team from Hong Kong.

Hide Caption

49 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Crowds watch sailing on large screens erected on the beach in Weymouth, England. Ben Ainslie of Great Britain became the most-decorated Olympic sailor after winning an event on home waters before thousands of supporters.

Hide Caption

50 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Serena Williams revels in the moment as she plays with her sister Venus against the Czech Republic's Andrea Hlavackova and Lucie Hradecka during the women's doubles gold medal match.

Hide Caption

51 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Serena Williams, left, and Venus Williams, right, return a shot during the women's doubles final.

Hide Caption

52 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Left to right: Kenya's Priscah Jeptoo, Ethiopia's Mare Dibaba, Kenya's Mary Jepkosgei Keitany, Ethiopia's Tiki Gelana and Kenya's Edna Ngeringwony Kiplagat lead the pack in the women's marathon. Gelana would go on to win the gold medal.

Hide Caption

53 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Thornton McDade of South Africa and Muhammad Imran of Pakistan challenge for the ball during a men's field hockey match.

Hide Caption

54 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Spectators view the course as rain falls during the women's marathon race.

Hide Caption

55 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Japan's table tennis team celebrates a point for Koki Niwa against Hong Kong's Peng Tang during a men's quarterfinal match.

Hide Caption

56 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Lin Dan of China strikes the shuttlecock on his way to winning the men's singles gold medal against Chong Wei Lee of Malaysia.

Hide Caption

57 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Erwan Le Pechoux of France faces off against Alexander Massialas of the United States during the men's foil team fencing quarterfinal.

Hide Caption

58 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – The Czech Republic's Andrea Hlavackova, left, and Lucie Hradecka, right, play against Venus and Serena Williams of the United States during the women's doubles gold medal match in Wimbledon.

Hide Caption

59 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Czech Republic guard Katerina Elhotova, center, attempts a shot during a women's basketball preliminary round match against Angola.

Hide Caption

60 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Members of the South African men's field hockey team celebrate a goal against Pakistan during a preliminary round match.

Hide Caption

61 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Japan's Koki Niwa serves to Hong Kong's Tang Peng during a men's team table tennis quarterfinal match.

Hide Caption

62 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Erika Matos, left, of Brazil takes a punch from Karlha Magliocco of Venezuela in a women's flyweight boxing round of 16 match.

Hide Caption

63 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Pakistan and South Africa square off in a men's field hockey match at Riverbank Arena Hockey Centre in London.

Hide Caption

64 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Runners make their way through London during the women's marathon.

Hide Caption

65 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Lin Dan of China celebrates winning his men's singles badminton gold medal match against Chong Wei Lee of Malaysia.

Hide Caption

66 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – South Korea's Yang Hyo-Jin, top right, spikes as China's Ma Yunwen, bottom right, attempts to block during the women's preliminary pool B volleyball match.

Hide Caption

67 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Namibia's Helalia Johannes, right, and other competitors begin to recover after finishing the women's marathon.

Hide Caption

68 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Competitors take part in the women's marathon event as rain falls on Day 9 of the London 2012 Olympics.

Hide Caption

69 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Team Japan celebrates defeating China during the men's foil team quarterfinals fencing event at the ExCeL center Sunday.

Hide Caption

70 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Spectators cheer from the stands during track cycling events at London Velopark in east London.

Hide Caption

71 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – South Korea's Lee Yong Dae, left, and Chung Jae Sung celebrate their victory over the Malaysian team during the bronze medal men's doubles badminton match.

Hide Caption

72 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Members of the Dominican Republic women's volleyball team attempt to block a shot during a preliminary match against Algeria.

Hide Caption

73 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Britain's James Davis, left, fences against Italy's Andrea Baldini during the men's foil team quarterfinals.

Hide Caption

74 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Long Chen of China celebrates winning the bronze medal in the men's singles badminton event, beating Hyun Il Lee of South Korea.

Hide Caption

75 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Algeria's Sehryne Hennaoui, right, dives for a shot during the women's preliminary pool volleyball match against the Dominican Republic.

Hide Caption

76 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Spectators cheer on Victoria Pendleton of Great Britain during a women's sprint track cycling qualifier.

Hide Caption

77 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Lyubov Sulika of Ukraine wears an Olympic rings pendant as she prepares for a women's sprint qualifying track cycling event.

Hide Caption

78 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – South Korea's Lee Yong Dae, right, plays a return next to his partner, Chung Jae Sung, in the bronze medal men's doubles badminton match against Koo Kien Keat and Tan Boon Heong of Malaysia.

Hide Caption

79 of 80

Day 9: The best photos of the Olympics80 photos

Day 9: The best photos of the Olympics – Peter Joppich of Germany celebrates beating Alexey Cheremisinov of Russia during the men's foil team fencing quarterfinal. Check out photos of Day 10 of the competition from Monday, August 6.

JUST WATCHED

Big day for UK at Olympics

MUST WATCH

JUST WATCHED

Linford Christie's Olympic picks

MUST WATCH

Linford Christie's Olympic picks 02:40

PLAY VIDEO

"After six races I was in a bit of trouble. Thankfully I turned things around and got it right when it counted. This was one of the hardest courses I have raced on and I don't want to do anything like that again.

"You can never say never but I don't think I can sail one of these again, it's killing my body so I don't think you will see me in Rio. But it's the best way to bow out at a home Olympics."

Ainslie claimed a silver medal in the Laser class at the Atlanta Games in 1996 and then gold four years later in Sydney.

He switched to the heavyweight Finn division at Athens in 2004 and took another gold, which he successfully defended in Beijing.

Ainslie endured a disappointing start to the regatta and didn't beat Hogh-Christensen until the seventh race but maneuvered himself into contention in the last of the fleet races.

The Briton kept himself ahead of his Danish rival but slipped down the field and was dangerously close to losing his gold when Postma challenged New Zealand's Dan Slater for second place.

But Postma clipped his rival's boat and had to take a penalty turn, ending his hopes and handing Ainslie another Olympic triumph. It came as a relief to Ainslie, who had been expected to deliver in front of his home crowd.

"It's been incredibly hard -- there's a huge amount of pressure to perform at a home Games," he added. "It's been the hardest couple of weeks of my life but you just have to get on with the job.

"I learned to sail for fun so it's been a long road but I have had a lot of support over the years and I am just so glad to have done it."

Earlier in the day, Team GB's Iain Percy and Andrew Simpson were piped to the Star gold medal by Sweden's Max Salminen and Fredrik Loof.

Percy and Simpson, who won the two-hand Star class in Beijing four years ago, went into the final race leading but could only finish eighth, leaving the door open for the Swedes.

The Brazilian pair of Robert Scheidt and Bruno Prada took the bronze medal.