Singapore’s Joseph Schooling won his nation’s first ever Olympic gold medal with victory in the 100m butterfly as Michael Phelps was one of three men to finish joint second.
Schooling, 21, won in an Olympic record time of 50.39 seconds.
The Singaporean was always in control and won by 0.75 seconds from the trio of Phelps, South Africa’s Chad le Clos and Hungary’s Laszlo Cseh.
Phelps, 31, could win his 23rd gold in the 4x100m medley relay on Saturday.
The American was not part of his country’s team that qualified for the final having taken the afternoon off after winning his 22nd gold in the 200m individual medley on Thursday.
Phelps, who was denied a fourth successive gold in the 100m butterfly by Schooling, will end his Olympic career by competing in the final race in the Rio pool.
“This is it. I’m not doing it. I swore in London I wasn’t coming back but this is final,” he said.
Schooling said of his win: “I’m just ecstatic. I don’t think it has set in yet. It’s just crazy.
“I hope that Michael can stay around long enough for me to race him again. I’d love that.”
It isn’t every day you come face to face with your childhood idol – and defeat him at the Olympics.
Singapore’s Joseph Schooling defeated decorated US Olympian Michael Phelps in the 100m butterfly swimming race and won his country’s first-ever Olympic gold medal.
“It feels great – kind of feels surreal right now, it’s crazy,” he said.
“I really can’t describe how this moment feels. All the adrenaline is running through my veins right now. It’s a dream come true.”
Celebration and praise has poured in from his countrymen back home, who flooded social media early on Saturday morning with congratulations for their man in Rio.
Singapore’s Prime Minister Lee Hsien Loong also took to Facebook to congratulate the new Olympian.
“This is Singapore’s first Olympic gold medal ever and also our first medal for ?the Rio Olympics,” he wrote in a post that gathered tens of thousands of likes and comments.
“My heartiest congratulations to Joseph Isaac Schooling for his historic gold medal win. It is an incredible feat to compete among the world’s best – stay focused and emerge victorious.
But to many Singaporeans following Schooling’s Olympic journey, it was all about the emotions of seeing him meet his childhood idol back in the Olympic swimming pool – eight years after they first met.