The Court of Arbitration for Sport's (CAS) saw a panel of three judges rule 2-1 that "on the basis of the evidence submitted by the parties, such discrimination is a necessary, reasonable and proportionate means of achieving the IAAF's aim of preserving the integrity of female athletics in the Restricted Events". 

Semenya, who did the 2018 Commonwealth Games 800-1500m double on the Gold Coast, will now have to medicate to suppress her testosterone levels if she wants to defend her world title later this year.

Under the IAAF's policy, all athletes with Difference of Sex Development (DSD) would have to reduce their testosterone levels to below five nmol/L for a continuous period of at least six months and maintain those levels for the rest of their athletic career, if they want to compete in middle distance events.

"I know that the IAAF's regulations have always targeted me specifically," Semenya said in a statement.

"For a decade the IAAF has tried to slow me down, but this has actually made me stronger.

"The decision of the CAS will not hold me back. I will once again rise above and continue to inspire young women and athletes in South Africa and around the world."

During the five-day hearing which took place last month, Semenya's team argued the policy was discriminatory, unfair, and was a potential health risk but the IAAF reiterated that the policy was about creating a level playing field for all woman.

The ruling effectively means that testosterone can be used to decide whether someone is a male or female.

Despite the result, the IAAF funded study used as "evidence" to back this decision, provided no evidence for causality between androgen levels and athletic performance.

However, Semenya's hands were tired when she came to appealing the policy as Kristen Worley explains to CBC.

The ruling will come into effect on May 8.