Sonny Bill Williams has recommitted to New Zealand Rugby through to the end of the 2019 season and also signed for the Blues in Super Rugby.
30-year-old Williams, who has played 33 Tests for the All Blacks, won two Rugby World Cup medals and featured in six tournaments for the All Blacks Sevens team, will play for the Blues for the same period.
New Zealand Rugby Chief Executive Steve Tew said: "This is another very important moment for New Zealand Rugby. We would like to, firstly, thank Sonny for his commitment and the manner in which this negotiation has been conducted."
"We know our top players have choices regarding where they play their footy and for him to sign a three-year deal with us shows he is truly motivated and excited about the opportunity and challenge of being remembered as a great All Black. He has also brought that passion and professionalism into the All Blacks Sevens team since making his debut with them this year.
"There is no doubt that he is a very special person. Since first signing with New Zealand Rugby back in 2010, he has made a significant impact, not only on the field but off the field as well. He is a huge star with particularly our younger fans and has been an inspiration to a whole generation of kids who, like Sonny, love the game of rugby."
All Blacks Head Coach Steve Hansen added: "It's great news for New Zealand Rugby having Sonny available for the next three years. He is an extraordinarily gifted athlete and thoroughly professional in everything he does. His recommitment will bring a stability to the midfield and will allow us to build a world-class centre combination. Sonny's professionalism, both on and off the field, will not only be an asset to his fellow midfielders, but also the rest of the team."