Conor Dwyer has announced his retirement from the sport ©Getty Images

Double Olympic gold medallist Conor Dwyer has announced his retirement from swimming after he was given a 20-month doping ban for having testosterone pellets inserted into his body.

The United States Anti-Doping Agency (USADA) said the 30-year-old two-time Olympic relay champion had tested positive for testosterone in two out-of-competition tests in November and one in December.

The ban rules him out of competing at next year's Olympic Games in Tokyo, although Dwyer claimed it was not the main factor in his decision to retire.

A three-member American Arbitration Association panel found he had "testosterone pellets inserted in his body in violation of the rules".

Dwyer, a three-time world champion in relays, claimed his doctor had been assured the United States Olympic and Paralympic Committee (USOPC) had approved the treatment.

The 200 metres freestyle bronze medallist at the 2016 Olympic Games in Rio de Janeiro also pointed out how the panel had said he bore "no significant fault or negligence" for the anti-doping rule violation.

Conor Dwyer won relay gold and individual bronze at the 2016 Olympic Games in Rio ©Getty Images
Conor Dwyer won relay gold and individual bronze at the 2016 Olympic Games in Rio ©Getty Images

"As noted in the Panel's decision, USADA is independent of sport and here to help athletes ensure they compete clean and protect their health and wellbeing within the rules," said USADA chief executive Travis Tygart.

"It's frustrating that Mr Dwyer did not take advantage of this support and hopefully this case will convince others to do so in order to protect fair and healthy competition for all athletes."

Dwyer was a member of the US relay teams which won the 4x200m freestyle gold medal at the London 2012 and Rio 2016 Olympic Games.

He also earned gold in the same event at the 2011 and 2013 World Championships, and was part of the victorious 4x100m mixed freestyle squad at the 2015 World Championships.

"My doctor assured me that the United States Olympic Committee had approved the treatment before I agreed to it," Dwyer said.

"Absent of these assurances, I never would have agreed to this medically necessary treatment.

"Regardless of the result of the arbitration ruling, I have decided to retire from swimming to pursue other professional interests.

"It was an honour to represent my country alongside my team mates and with the support of my coaches, family, and friends."