Dual-code superstar Sonny Bill Williams announced his retirement from rugby on Thursday and says he will turn his attention to his boxing career. Williams, 35, a two-time Rugby World Cup winner with the New Zealand All Blacks, confirmed he would no longer play for Australia's National Rugby League outfit the Sydney Roosters. "A massive thank you to the public and fans for all the support over years. To my many teammates, thanks for the lessons and help along the way," he tweeted. "It wasn't a perfect journey, but the lessons have helped shape me into the man I'm proud to be off the field today." Williams retires as one of rugby's most successful players and one of its most colourful characters. He won Rugby World Cups in 2011 and 2015 with the All Blacks, as well as numerous Bledisloe Cup titles against Australia and Rugby Championships. He also won NRL Premierships in 2004 (Canterbury Bulldogs) and 2013 (Roosters), represented New Zealand in rugby sevens at the 2016 Olympics and won all seven of his professional heavyweight boxing bouts. Williams' power and pace allowed him to play a variety of positions but he will perhaps be best remembered playing in the centres in union and was renowned for his one-handed offloads and fierce tackling. Off the field, the devout Muslim used his profile to speak up on causes such as refugee welfare and cultural tolerance. Former All Blacks coach Steve Hansen last year rated Williams the "best athlete he had ever worked with", and described him as "a freak of nature". The All Blacks paid tribute to the 58-Test veteran. "The offload king. Thank you for all you've given to New Zealand rugby and fans all around the world, @SonnyBWilliams. Enjoy retirement uso (brother)," the team tweeted. Williams said retiring from team sports would allow longer preparation for his boxing bouts. "I spoke to my manager, I said 'Bro I'm keen to get back into the ring, I've got a couple of years, I'm 35'," he told Australia's Channel Nine. "I spoke to the wife first and she had blank eyes but like usual, she supported me." Williams beat South Africa's Francois Botha by unanimous decision to win the WBA international heavyweight title in February 2013. In October 2013, Williams revealed he would not fight again for at least three years due to a lack of time as he pursued his rugby commitments. This led to him being stripped of his two titles. Williams' last bout was in January 2015, when he beat American Chauncy Welliver at Allphones Arena in Sydney. Williams is now based in Sydney and a fight against former Cronulla Sharks enforcer Paul Gallen would generate huge interest in Australia, although Gallen insisted Thursday he had "bigger fish to fry".