-- Michael Phelps heads into retirement the only way imaginable – with an 18th Olympic gold medal.

Since his Olympic debut as a 15-year-old in Sydney a dozen years ago, Phelps has won twice as many golds as any other Olympian. His total of 22 medals is easily the best mark, too.

Phelps capped off a mind-boggling career with a victory in the 4x100-meter medley relay Saturday.

Here's a look back at Phelps' Olympic career in photos:

Loading Slideshow...
  • FILE - In this Aug. 16, 2008 file photo, United States' Michael Phelps reacts as he wins gold in the final of the men's 100-meter freestyle during the swimming competitions in the National Aquatics Center at the Beijing 2008 Olympics in Beijing. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Mark Baker, File)

  • FILE - In this Aug. 14, 2004 file photo, Michael Phelps, of the United States, smiles with his gold medal after setting a world record in the 400-meter individual medley at the Olympic Aquatic Centre during the 2004 Olympic Games in Athens. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Mark J. Terrill)

  • FILE - In this Aug. 16, 2004 file photo, Michael Phelps, of the United States, swims in a qualifying heat of the 200-meter butterfly at the Olympic Aquatic Centre during the 2004 Olympic Games in Athens. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Mark J. Terrill)

  • Michael Phelps

    FILE - This combination of photos shows United States' Michael Phelps holding each of his eight gold medals after (top, left to right) the 400m individual medley, 4 x 100m freestyle relay, 200m freestyle, 200m butterfly, (bottom, left to right) 4 x 200m freestyle relay, 200m individual medley, 100m butterfly and the 4x100-meter medley relay at the Beijing 2008 Olympics in Beijing. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo, File)

  • Michael Phelps

    FILE - In this Aug. 11, 2008 file photo, Michael Phelps celebrates the gold medal victory in the men's 4x100-metre final at the Beijing 2008 Summer Olympics in Beijing. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/The Canadian Press, Paul Chiasson, File)

  • FILE - In this Aug. 14, 2004 file photo, Michael Phelps, of the United States, jumps off the blocks enroute to winning gold in the final of the 400 meter individual medley at the Olympic Aquatic Centre during the 2004 Olympic Games in Athens. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Mark Baker, File)

  • FILE - In this July 31, 2012 file photo, United States' Michael Phelps poses with his gold medal for the men's 4x200-meter freestyle relay swimming final at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Matt Slocum, File)

  • FILE - In this Aug. 15, 2004 file photo, Michael Phelps of the U.S. reacts after finishing in a semifinal heat of the 200m freestyle at the 2004 Olympic Games in Athens, Greece. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark, (AP Photo/Thomas Kienzle, File)

  • United States' swimmer Michael Phelps smiles as he wears his gold medal at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/Mark J. Terrill)

  • United States swimmer Michael Phelps acknowledges fans after winning a gold medal in the men's 4 X 100-meter medley relay at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics, London, Saturday, Aug. 4, 2012. (AP Photo/Jae C. Hong)

  • Michael Phelps

    FILE - In this Aug. 17, 2008 file photo, United States' Michael Phelps celebrates after winning his 8th gold medal after the men's 4x100-meter medley relay final during the swimming competitions in the National Aquatics Center at the Beijing 2008 Olympics in Beijing. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark. (AP Photo/David J. Phillip, File)

  • United States' Michael Phelps swims in the men's 4 X 100-meter medley relay at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. Phelps retires with twice as many golds as any other Olympian, and his total of 22 medals is easily the best mark.(AP Photo/Julio Cortez)

  • Members of the United States team Matthew Grevers, left, Michael Phelps, middle and Brendan Hansen celebrates as Nathan Adrian finishes in the men's 4 X 100-meter medley relay at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. (AP Photo/Julio Cortez)

  • United States' Michael Phelps prepares to swim in the men's 4 X 100-meter medley relay at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. Phelps pushed the United States in front to win the medley relay Saturday in the final swimming event of the London Games, after which he is retiring. He leaves the sport with a record 18 golds and 22 medals overall. (AP Photo/Matt Slocum)

  • United States' men's 4 X 100-meter medley relay team from left, Matthew Grevers, Michael Phelps and Brendan Hansen shake hands with teammate Nathan Adrian after winning the gold medal at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. Phelps pushed the United States in front to win the medley relay Saturday in the final swimming event of the London Games, after which he is retiring.(AP Photo/Matt Slocum)

  • United States' swimmer Michael Phelps holds up a silver trophy after being honored as the most decorated Olympian at the Aquatics Centre in the Olympic Park during the 2012 Summer Olympics in London, Saturday, Aug. 4, 2012. (AP Photo/Matt Slocum)