Michael Phelps has won more medals than any other Olympian -- ever.
But now that he's finished his last race in Rio, what's next for the swimming superstar?
The 23-time gold medalist currently has contracts with Under Armour (UA), Omega and Aqua Lung, which makes MP branded swimsuits. And many retired athletes -- particularly those with long and decorated careers like Phelps' -- can continue to have lucrative endorsements for years.
In addition to his achievements in the pool, Phelps has also established a foundation that teaches water safety, introduces kids to swimming and provides financial assistance for athletes. And USA Swimming wants him to stay on as an ambassador and help it improve its relationship with retiring swimmers.
"More and more what we see athletes do is craft their legacy with brands long before they retire," said Elizabeth Lindsey, a marketing expert at Wasserman. "Phelps has done that with his foundation and by being more of a mentor. That sets a tone that could be a platform into retirement."
Related: How Michael Phelps changed the business of swimming
But for all his success, he's faced his share of scandals.
In 2004, he was arrested on DUI and sentenced to 18 months probation.
In 2009, he lost a sponsorship deal with Kellogg (K) and was suspended from competitive swimming for three months after a photo surfaced of him smoking from a bong.
He was again arrested for DUI in 2014, which was "telling," according to Patrick Rishe, director of the sports business program at Washington University in St. Louis.
"He wasn't a young man when this happened, and companies are going to be leery to invest in someone making those types of mistakes as an adult," Rishe told CNNMoney. "For any company trying to cater to family values, lingering videos of his drunk driving arrest and bong photos will make him less valuable."
Related: This swimmer missed his shot at Rio. Now, he's peddling coffee. Here's why.
Other factors that could affect Phelps' marketability are his impending retirement and the fact that he's been on the scene awhile. (Phelps has competed in five Olympic games.)
"He won't have any constant visibility [and] he's not a new shiny apple the way [swimmer] Katie Ledecky or [gymnast] Simone Biles are," Rishe said.
Phelps has appeared contrite about the various scandals he's faced, which could be redeeming, Rishe noted.
Lindsey said the fact that Phelps attended rehab might further show that he's trying to make a change, which could inspire confidence from companies.
From a marketing standpoint, Phelps does have several things going for him.
He's a new father, which makes him more relatable and might make consumers more forgiving of past transgressions.
He's further humanized by "his strong relationship with his mother, which played out on TV, and his struggles with his father," according to Lindsey.
Related: Stunning underwater Olympics shots are now taken by robots
She also noted that brands who pick athletes solely based on their on-field accomplishments are bound to be disappointed -- athletes get injured, quit, have bad seasons and retire.
With Phelps' career seemingly behind him, his legacy is fairly solid in the pool. But brands should focus on how their relationship with their athletes can continue outside of sports.
Rishe is confident Under Armour will stand by Phelps.
"Call it a hometown effect," Rishe said. "[They're] both based in Baltimore, and with a long-standing relationship already in place, UA will have a loyalty and level of forgiveness towards Phelps the way Nike did with Tiger Woods."