Spain's sports minister has acknowledged the country has a problem with doping that needs fixing.

Jose Ignacio Wert, minister for Education, Culture and Sport, says ''we have a problem with doping and that's why we have every intention of making sure Spain's anti-doping law conforms with WADA's anti-doping code.''

Wert says ensuring that Spanish legislation meets world standards is key to Madrid's bid to host the 2020 Olympics.

Spain's record on doping has been in the spotlight since Alberto Contador was recently banned over a failed drug test and stripped of his 2010 Tour de France title.

Wert says ''Spain needs to gain credibility'' with international sporting bodies.