WADA president John Fahey said the Games would be the most tested ever and that athletes owed it to their teams and their opponents, as well as the image of the Olympics, to play fair and quit before competing.
"I say this in the clearest way possible: if you are a doping athlete and you are planning to compete in London then you must withdraw from your Olympic team," Fahey said in a statement.
"Doping is cheating, plain and simple. And if you compete in London as a doped athlete then not only will you be cheating your fellow athletes, you will be cheating sports fans across the world, doing a disservice to your national flag and flouting the ideals of the Olympic Movement," he said.
The Games begins on July 27 and run until August 12 although the 'in-competition' testing period start with the opening of the Athletes Village on July 16.
There will be around 6,250 samples analysed at the Games while UK Anti Doping have also been mandated to test in pre-competition training camps.
"There has been a coherent effort to make London 2012 as 'clean' as possible and doping athletes should know that their chances of avoiding detection are the smallest they have ever been," said Fahey.
"A doping athlete cannot achieve success, it is a complete contradiction. Even if a doping athlete were to win a medal he or she would never be able to look at themselves in the mirror and say 'well done, I deserved this'," he added.
"The Olympic Games is the absolute pinnacle for many athletes, and for them to train endlessly over a four-year period and then have their efforts belittled by a doping athlete, to me that is complete and utter betrayal of what sport stands for."
There were 20 proven cases of doping at the Beijing Games four years ago, including six horses, down from 26 cases in Athens in 2004.
"Athletes are responsible for what they put into their bodies and athletes are responsible for whether or not they choose to dope," said Fahey.