The Court of Arbitration for Sport in Lausanne dismissed appeals by the World Anti-Doping Agency and International Tennis Federation, which wanted Gasquet banned for up to two years.
"I'm absolutely relieved. This is the end of a crazy story," Gasquet said. "I'm happy to be 100 percent cleared."
Story continues below ↓advertisement | your ad hereThe court accepted Gasquet's claim that he inadvertently consumed cocaine by kissing the woman in a Miami club hours after withdrawing injured from a tournament in March.
"It was impossible for the player, even when exercising the utmost caution, to know that in kissing a woman who he had met in a totally unsuspicious environment, he could be contaminated with cocaine," the court said in a statement.
A CAS panel of three lawyers said the quantity of the drug in Gasquet's urine test was "minute" and the 23-year-old Frenchman was "clearly not a regular cocaine user."
"The possibility of contamination became the most plausible explanation," CAS said.
Gasquet's coach, Eric Deblicker, told the Eurosport Web site that the case had been hard on the French player over the last few weeks.
"This is a huge relief, mostly for Richard and for the people close to him," Deblicker said. "The most important thing now is to see him enjoying on the court."
Deblicker also said Gasquet will play at the Brisbane and Sydney tournaments as part of his preparation for the Australian Open.
The verdict was greeted with dismay by WADA and the ITF, the sport's world governing body.
"WADA considered that the evidence warranted full and total scrutiny," director-general David Howman said in a statement. "WADA abides by the CAS ruling and has no further comment at this stage."
ITF president Francesco Ricci Bitti said the federation was "disappointed" with the court's ruling.
"The ITF also recognizes the potential implications of the CAS decision with respect to future decisions and will discuss these with WADA," he said.
The 23-year-old Gasquet served a 2 1/2-month suspension before an independent ITF tribunal cleared him to resume his career in July.
It ruled he was not to blame because the woman - identified only as "Pamela" - contaminated him with cocaine hours before the drug test.
CAS said that ban should not count as a doping offense on Gasquet's record, even though he had not appealed against it.
Athletes who commit two doping offenses face a life ban from their sport.
WADA and the ITF appealed to CAS because they believed Gasquet should be held to the strictest standards of the WADA Code, which makes athletes responsible for any substance found in their body.
They tried to deny him the defense of "no significant fault or negligence" for the drug being present.
Gasquet gave evidence at the appeal, which was heard over seven hours at CAS headquarters on Nov. 10.
The CAS panel found he "had not committed any fault or negligence within the meaning of the ITF anti-doping program."
In his defense, Gasquet said he went to the nightclub with friends to see a French DJ perform after pulling out of the Sony Ericsson Open in Key Biscayne with a shoulder injury. He met "Pamela" there and kissed her several times.
The court said both parties' experts "agreed that the minute amount of cocaine could have been transferred in this manner."
Gasquet can now prepare for the Australian Open in January. He missed the French Open and Wimbledon while suspended, and in his first main-draw match after returning lost to top-seeded Rafael Nadal in straight sets at the U.S. Open.
He is ranked No. 52 in the year-end ATP standings after being No. 23 when his failed test was announced in April.
Gasquet's ranking peaked at No. 7 in July 2007 after he reached the Wimbledon semifinals, where he lost to Roger Federer. He has earned more than $4.2 million (?2.9 million) in career prize money, according to the ATP.
"My highest ranking was seven in the world and I want to return in the top 10," Gasquet said.
© 2009 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.
Silva facing month outITF lifts bans, clears Wickmayer, Malisse