(CNN) -- A former international rugby star has shocked the sports world by revealing that he is gay.

Gareth Thomas, Wales' most-capped player after appearing in 100 Tests, made the surprise announcement in an interview with British newspaper The Daily Mail.

The 35-year-old retired from internationals after the 2007 World Cup, but still plays for Welsh provincial side Cardiff Blues.

He is the first openly gay top-level rugby player, although top referee Nigel Owens came out in 2007.

While homosexuality in a macho code such as rugby is rarely acknowledged, top-level tennis players such as Billie Jean King, Martina Navratilova and Amelie Mauresmo have discussed being lesbian.

Former NBA basketball star John Amaechi came out in his memoir in 2007 a couple of years after his retirement, while Olympic diving champion Greg Louganis was candid about his sexuality and tested positive for HIV in 1988.

Thomas married his childhood sweetheart Jemma in 2002, but they separated in 2006 and their divorce is being finalized.

"I've been through all sorts of emotions with this -- tears, anger and absolute despair," he said. "I wasn't sure if I ever wanted to let people know and, to be honest, I feel anxious about people's reactions and the effect it might have on my family."

He said he knew he had was gay from as young as 16 or 17, but hid it as he sought to establish his rugby career, later going on to captain the British and Irish Lions and becoming one of the top backs in international rugby.

"I could never accept it because I knew I would never be accepted as a gay man and still achieve what I wanted to achieve in the game," he said.

"I became a master of disguise and could play the straight man down to a tee, sometimes over-compensating by getting into fights or being overly aggressive because I didn't want the real me to be found out. But when you withdraw into yourself you start to feel lonely, upset, ashamed."

The player finally revealed he was gay to Wales coach Scott Johnson after a match in November 2006, and the Australian then informed his teammates Stephen Jones and Martyn Williams.

"They came in, patted me on the back and said, 'We don't care,'" Thomas said. "Two of my best mates in rugby didn't even blink an eyelid.

"It's pretty tough for me being the only international rugby player prepared to break the taboo. Statistically I can't be the only one, but I'm not aware of any other gay player still in the game.

"I'd love for it, in 10 years' time, not to even be an issue in sport, and for people to say: 'So what?'

"I don't want to be known as a gay rugby player. I am a rugby player first and foremost. I am a man. I just happen to be gay. It's irrelevant. What I choose to do when I close the door at home has nothing to do with what I have achieved in rugby."