Shane Williams will retire from all rugby at the end of this season, BBC Sport Wales understands.

Wales' record try scorer quit Test rugby in December, with 58 tries in 87 games for his country and two in four Tests for the British and Irish Lions.

Wing Williams, who turns 35 this month, has a contract with the Ospreys until the end of the 2012-13 season.

The Welsh region had also offered Williams a year extension, but he has decided to hang up his boots for good.

Williams signed off from the international stage in typical fashion, scoring a last-gasp try in the 18-24 defeat to Australia in Cardiff on 3 December.

"He has been amazing for Wales, Ospreys and the Lions," Wales skills and kicking coach Neil Jenkins said.

"He is a huge player, a Welsh rugby great, and he will be sorely missed.

"It is difficult - and I have done it myself - when you come to the end of your international career.

"That is what you have played for all your life and Shane is no different to me. He feels the time is right, and only he knows.

"He has had an outstanding career. He helped the youngsters in the squad, taking them to one side and doing different things with them, and he has been a massive help to us on and off the pitch."

At 5ft 7in and 12st 8lb Williams bucked the trend for powerhouse wingers in the professional game and in 2008 was named the International Rugby Board Player of the Year.

Williams has already expressed a desire to become a coach and has previously spoken to Ospreys managing director Mike Cuddy and elite performance director Andrew Hore about his post-playing career prospects.

Against the Springboks four years later Williams again had to bide his time, but he came off the bench in the second Test and then started the third Test - scoring two tries in a 28-9 win that restored some Lions pride.

To date Williams has played 136 times for the Ospreys, scoring 54 tries in the process for the Swansea-based side.

Watch a special programme dedicated to Shane Williams on BBC Two Wales, Friday 3 February 2100 GMT.