Updated

It was a familiar scene, Michael Phelps atop an Olympic medal podium, gold medal hanging from his neck.

No one has ever done it more. Maybe no one ever will. And if what Phelps says is true, it's the last time we'll see him in that position.

"It's wild. Twenty years. I couldn't ask to finish on a better note. I've done everything I've ever wanted to do and I'm very happy," Phelps said, struggling to sum up his career in a late-night press conference after winning what he says will be his last race.

"I don't think everything has really struck me yet about what's happened," he said. "I'm sure over the next few days things will really start to set in."

Phelps retired on top, the most decorated Olympian in every way possible after swimming the butterfly leg for the heavily-favored American 400-meter medley relay team Saturday night.

He won his 18th gold and 22nd Olympic medal overall in his final competitive swim, extending both records.

Phelps actually stood atop the medal podium twice -- once during the medal ceremony with teammates Matthew Grevers, Brendan Hansen and Nathan Adrian, when he fought back tears during "The Star-Spangled Banner" -- and again when he stopped back for one last time, holding a silver trophy given to him by FINA to celebrate his accomplishments.

The Aquatics Centre was packed on the last night of swimming here, and many stuck around to bid Phelps farewell.

The U.S. relay teammates held up a white banner with the words: "THANK YOU LONDON." Someone near the top of the arena screamed, "We love you, Michael!" And as one of the greatest days in British Olympic history unfolded next door during track and field, some folks decked out in the Union Jack tried to get a "Michael! Michael! Michael!" chant going.

Phelps lingered, taking a victory lap, stalking around the pool to show the trophy to spectators and photographers. He joked with an Olympic volunteer as they walked between the swimming and diving pools. They both smiled.

This was some farewell.

"What he did for the sport will remain forever," said Hansen.

The records should stand for a while, at least, until some other young gun comes along with a bag full of strokes and a body built for swimming the way Phelps' was. Perhaps that swimmer's already arrived -- Missy Franklin, maybe -- but the present belongs to Phelps.

He won six medals in seven races here -- his only loss came Day 1 -- including another four golds and his first two silvers. It was two fewer medals than he captured in each of the last two games, and half as many golds as his record haul in Beijing four years ago.

Phelps shared the spotlight with Ryan Lochte entering London and left with the light all to himself.

His final race wasn't quite a laugher, but there was never really any doubt about the outcome with medalists from all four strokes swimming on the U.S. team.

Grevers, the 100 backstroke champ, gave the Americans a lead after 100 meters. They trailed Japan after Hansen's breaststroke leg but Phelps had them back on top by .26 seconds after 300 meters and 100 freestyle champion Adrian locked it down with a fast split, touching the U.S. team in 3 minutes, 29.35 seconds -- 1.91 ticks ahead of Japan.

"I'm nothing compared to Michael," said Japanese breaststroke legend Kosuke Kitajima, who swam in the relay. "It was a wonderful experience for me that we were able to swim together in that last relay."

The U.S. swept the medley relays on the last night of swimming.

Earlier, Franklin became the first American female to swim in seven Olympic events when she led off in a record-setting win by the U.S. in the women's 400 medley team.

Franklin, Rebecca Soni, Dana Vollmer and Allison Schmitt swam the race in 3:52.05 to take .14 seconds off China's old world record from 2009. Australia ended 1.97 seconds back in second place and Japan was third.

Franklin, 17, swam the leadoff backstroke laps and won her fifth medal in London, including four golds to cement her place as the new young star in U.S. swimming.

Phelps leaves U.S. swimming in the hands of the likes of Franklin and 15-year- old Katie Ledecky, the 800 free champion.

Yes, he swears he's done. Don't expect him to pull a Brett Favre, coming back for another chance only to retire again. Only to come back, only to retire, and on and on.

Phelps, just 27, has always said he doesn't want to still be swimming by the time he's 30. And he knows if he swims one, two, three more years, it will mean swimming four more years. It will mean another Olympics.

He'd like to travel, please, to see other parts of cities around the world besides their hotels and pools. He's seen so many interesting places, but never really SEEN them, if you know what he means.

There's a chance his first stop will be South Africa, where he says he wants to cage dive with sharks. Chad le Clos, the 20-year-old South African who beat his hero in the men's 200 fly here, may have talked him into that one.

"I've been very fortunate to look back over my career and say I've been able to accomplish every goal that I've ever wanted to. And I think at that point in your career, it's just time to move on," said Phelps.

"There are other things that I want to do in my life and I'm not sure staring at a black line for four hours a day is one of those."