Manchester United will play Juventus in a testimonial game for Gary Neville at Old Trafford on Tuesday 24 May.
Neville, 36, announced his retirement on 2 February after spending his career with United, making 602 appearances.
He said: "I am delighted to be given this game by the club, it is going to be a very emotional night, especially as I pull on that red shirt once more.
"I intend to savour every moment and I hope the fans can share in my special night," he added.
Neville made his debut as a 17-year-old against Torpedo Moscow in a Uefa Cup tie in 1992.
He was part of the United team that won eight Premier League titles, three FA Cups, two League Cups and the Champions League in 1999.
On the way to their dramatic victory in the final against Bayern Munich at the Nou Camp, United defeated Juventus in the semi-finals.
Neville has pledged to use the money raised by the match for community projects and supporter initiatives in the UK and abroad.
Manchester United manager Sir Alex Ferguson said: "Gary has been a loyal servant of Manchester United and this is a fitting tribute to honour Gary and his career.
"It also gives the fans the opportunity to show their admiration and appreciation for a player who is very much one of them. We have had many great games against Juventus in the past and I am sure this will be another memorable night."
Neville retired after a series of injuries had affected his performances and his last competitive match was on 1 January in the 2-1 Premier League win against West Bromwich Albion at The Hawthorns.
He had hoped for a testimonial before the season started but was forced to put the game back because a suitable date could not be arranged.