Phelps ended his incredible Olympic career on the perfect note on Saturday, winning his 18th gold medal for the United States in the men's medley relay, the last time he will swim a competitive race.
Swimming the butterfly leg, the most decorated Olympian of all time went out as the ultimate winner when he joined forces with backstroker Matt Grevers, breaststroker Brendan Hansen and freestyler Nathan Adrian to crush their opponents and win the gold.
The four set a combined time of three minutes, 29.35 seconds, just outside the world record set by the Americans at the 2009 world championships in Rome, but it hardly mattered.
Japan finished second after leading at the halfway stage while Australia stormed home to collect the bronze but no country was ever going to stand in the way of an American team determined to give Phelps the send off he deserved.
The 27-year-old was swimming his last race before retiring after breaking every imaginable record during his career and providing a last memory of his determination to win.
The US were ahead after the opening backstroke leg but slipped back to second following the breaststroke.
Then Phelps dived in for the last time and by the time he got back to handover to Adrian, the Americans were back in front and the result was a foregone conclusion.
In London, Phelps won four gold and two silver medals to finish his career with a total of 22 medals, four more than Soviet gymnast Larisa Latynina, who held the previous record for almost half a century before Phelps set a new mark that could last even longer.
Phelps already had the record for the most gold medals.
By picking up his 18th, he finished his career with twice as many as the next best, the nine jointly held by Latynina, American athlete Carl Lewis, American swimmer Mark Spitz and Finnish distance runner Paavo Nurmi.
Unlike the men, the American ladies were able to set a new world's best.
Franklin, swimming the backstroke leg, teamed up with breaststroker Rebecca Soni, butterflyer Dana Vollmer and freestyler Allison Schmitt to win the gold in a combined time of three minutes, 52.05 seconds.
The Americans led at every handover and shaved 0.14 seconds off the previous world record of 3:52.19 set by China at the 2009 world championships in Rome when the now-banned polyurethane bodysuits were still allowed.
Australia finished second to grab the silver medal while Japan came third to collect the bronze but neither were able to keep up with the Americans after Franklin gave them the lead after the lead-off leg.
Franklin, 17, also won gold in the 4x200 freestyle relay and the 100 and 200 backstroke and became the first swimmer in London to win four golds.
Vollmer and Schmitt both won their third gold medals in London while Soni picked up her second.
Gemma Spofforth, Siobhan-Marie O’Connor, Ellen Gandy and Fran Halsall swam 3:59.46 mins to finish eighth.
And Spofforth, who is widely expected to retire at the end of the Games said she was proud to finish off with a good performance.
“We all came here wanting a lot more medals than we came out with but I’m so proud of the team,” she said.
“We’ve got so many people into finals a lot more than we ever have done.
“We can just be proud but all of us came here for a medal and obviously none of us came away with one so it is a little bit sad for us.
“These girls are amazing and it’s been amazing to be around them the whole time.”
O’Connor, the youngest swimmer in the team at just 16 years old, was over the moon to compete with the best in an Olympic showpiece.
“It’s been such a whirlwind,” she said. “To be in an Olympic final is the best thing ever in front of a home crowd – it was amazing and I will never forget it.
Gandy, who also competed in both the 100m and 200m butterfly here in London, was happy to end an up and down Games on a high.
Liam Tancock, Michael Jamieson, Michael Rock and Adam Brown posted a time of 3:32.32 minutes to come in fourth behind the USA.
And 27-year-old Tancock was proud the team signed off from a successful Olympic meet with an equally impressive swim.
“Absolutely awesome performance by the guys here,” he said. “We’ve had a great week in the pool with multiple finals and we’re really stepping up.
“The crowd is supporting us. This was the last race of the whole meet and the whole Olympics for us and these guys really stepped up going a lot faster than we’ve gone in the heats earlier. It was so close but great race.”
Jamieson, who claimed silver in the 200m breaststroke earlier in the week, was understandably disappointed to miss out on another medal but proud of the team’s overall performance.
“It’s been amazing such a pleasure to race here,” said the 23-year-old Scotsman. “That is six races in front of this crowd and every one of them has been amazing.
“We knew it was going to be tough tonight but we also knew we had a chance. Everyone stepped up again tonight and it’s a lot faster than we went in the heats.
“Another fourth place is a little bit disappointing but it was a great race by everyone.”
And 25-year-old Rock was proud to be part of a team that swam over a second faster than they did in yesterday’s heats where they qualified second fastest.
“It’s just an honour to be part of that,” he said. “I love teaming up with the guys and we went over a second faster than yesterday.
“It was a great performance to get that centre lane for the final and it has been just the best experience – the home support and the whole Olympics – I’ve loved every second of it.
“I’m very honoured to share the pool with him (Phelps) tonight and that was very special for me.”
Brown, who trains in the United States, knew he had to step up in such a competitive field but was in positive mood about the team’s chances going forward.
“The competition we do over in the States really helps,” he said. “You’re used to all the waves with all the short course swimming.
“I knew I would be racing against Nathan (Adrian) who won the 100m and James Magnussen who came second in the 100m. I was in the middle of them two and I tried my hardest to bring it home for the boys.
“I’m really pleased with the fourth place considering we came in here seeded 14th – we’ve jumped up ten spots.
“Who knows if we are all still together in four years’ time. In Rio we’ll be in the medals hopefully.”
- Nathan Adrian