Most know that U.S. Olympians who perform well tend to get millions of dollars in endorsement deals, but did you know they also get big payouts just for medaling in the games?

The U.S. Olympic Committee pays American athletes $25,000 for gold medals, $15,000 for silver medals and $10,000 for bronze medals. That means swimmer Michael Phelps – the most-decorated Olympian – has received $615,000 just for his medals from the committee since 2004. He has one more chance to medal in Rio de Janeiro, so he could bring that total up to as much as $640,000 by the end of the 2016 games.

And that’s just from the committee. USA Swimming is among the most generous Olympic sport organizations, giving an additional $75,000 for gold medals, plus an extra $50,000 for setting a new world record. So Phelps has earned more than $1 million just for Olympic participation. He’s reportedly worth about $55 million.

The downside: Prize money – and even the medals themselves – are not tax free. Tax rates on the prize money depend on annual income, with the highest rate at 35 percent. Gold medals themselves are subject to a tax of up to $9,000.

It’s a regular tradition for Congress to introduce legislation to make Olympic medals and prize money tax free, but no bills have been passed.

Rewards from the U.S. Olympic Committee were increased for the Salt Lake City Winter Olympics in 2002, from $15,000 for gold, $10,000 for silver and $7,500 for bronze, according to Forbes. Those rates were introduced in the 1994 games, and before that every U.S. athlete that placed in the top eight of their event received $2,500.

Forbes estimates that the U.S. Olympic Committee will shell out about $5 million total for the Rio Olympics. The committee is funded by private donations and not tax dollars. A representative of the committee did not immediately return a request for comment.

“American medalists at the 2012 games collected just under $5 million in total, while four years previously the aggregate payout came to $5.3 million, the biggest distribution USOC has ever made for medal bonuses,” Forbes reported.

The U.S. is somewhere in the middle on medal bonuses. The United Kingdom is one country that doesn’t give any money for medals, while Canada and Australia give $20,000 for first-place finishers. Other countries reportedly give six-figure payments, including host country Brazil, where a gold medal is worth $250,000. Singapore gives a whopping $800,000 per gold medal.