Wales captain Sam Warburton has ended speculation about his future by signing a national contract with the Welsh Rugby Union (WRU).
Warburton's salary will be paid by the WRU but he will continue to play for Cardiff Blues and will be released for games outside his Wales duties at no cost to the region.
The 25-year-old is the first player to sign a central contract with the WRU.
"I am delighted to commit my future to Welsh rugby," said Warburton.
"Now that my future is secured within Wales I look forward to focusing on the Six Nations and beyond."
BBC Wales Sport understands the contract will take Warburton up to the 2017 British and Irish Lions tour to New Zealand.
The contract also ensures that Warburton, who captained the Lions on their victorious tour of Australia last year, will be released for all Wales international duty as required but does not guarantee him selection to the squad or team.
The Cardiff Blues have yet to respond to the news of Warburton's deal but the region's chairman Peter Thomas has claimed the Welsh regions and Welsh Rugby Union were in a "crazy" competition to sign Wales' top players.
Wales players have previously been contracted to their regions or teams and the regions had an agreement not to field a centrally-contracted player.
The WRU said the agreement was "a triumph in the best interests of all Welsh rugby".
"We have been able to strike a deal which ensures the Welsh captain will continue to play his rugby at the highest level here in Wales," WRU group chief executive Roger Lewis said.
"I am extremely grateful to the Cardiff Blues chairman, Peter Thomas, for his understanding when the WRU chairman [David Pickering] and I met him on Wednesday to outline this proposed plan.
"Welsh rugby together cannot stand back any longer and watch its best players leave Wales. We all have to act together and act now in the best interests of the game.
"There can be no better message to current and future internationals than the decision of Sam Warburton to become the first senior player to sign a WRU national contract and commit to regional rugby and international rugby in Wales.
"This is all about us working together in the best interests of rugby in Wales and I am sure this will be remembered as an important moment for rugby in Wales."
The flanker's current contract with the Cardiff Blues expired in the summer and in December he had set a deadline for his future to be sorted out.
Uncertainty over Warburton's club career came against the backdrop of the dispute between the Welsh Rugby Union and the four regions.
The two sides are in dispute over funding, proposed new competitions and the exodus of players to richer clubs in France and England.
Warburton's Cardiff Blues team-mate Leigh Halfpenny has become the latest player to join the Welsh exodus, signing for French side Toulon on a two-year deal.
However fellow international Alun Wyn Jones will remain in Wales after agreeing a new two-year contract with the Ospreys.
"This has been a significant week for Welsh rugby with the two Lions Test captains Alun Wyn Jones and Sam Warburton committing to playing the game in Wales," Lewis added.