Patrick Vieira is set to join Juventus on Friday after Arsenal accepted a £13.75m offer for their skipper.
The 29-year-old French international midfielder, who has been at Highbury since 1996, is now discussing personal terms with the Italian side.
A club statement said: "We can confirm that terms have been agreed for the transfer of Patrick Vieira to Juventus for a total fee of 20m euros."
Vieira has flown to Turin and will undergo a medical on Friday.
The midfielder, who is expected to sign a five-year deal with Juve, was the first signing for manager Arsene Wenger when he arrived at the club.
Reports in Italy suggest Juventus will pay an initial instalment of £6.88m, with payments of £3.44m to follow in July 2006 and July 2007.
Wenger said: "I share the sadness with our supporters that Patrick has left us.
"But on the other hand I would say to them 'trust us and support us'. The sad thing is he leaves us, but the good thing is that he leaves us on a high.
"Patrick was a great player for us, one of the greatest in the club's history and I feel I had a special relationship with him because I made him come here.
"I think his impact, not only at Arsenal but in English football overall, was just tremendous."
Joined Arsenal: Aug 1996 (Arsene Wenger's first signing)
Made captain: June 2002
Premiership titles: 3
FA Cup medals: 4
Red cards: 10
Vieira has been linked with a move away from Highbury for the last few summers, and was said to be close to a £23m switch to Madrid last summer.
But he admitted he is in need of a new challenge after nine years with the north London club.
He said: "When you spend nine years at the club, like I did, it is a difficult decision to leave.
"But in the end you have to make a choice for your future. It was a very difficult decision, but I am happy with it.
"I made the decision to leave because I felt it was time for me to have a new challenge. But that does not mean I was unhappy or that I was having a problem at Arsenal.
"It was just that I had the feeling I needed to grow and meet a new challenge, and I feel Juventus was the best challenge for me.
"I'd like to thank the Arsenal fans. They have been fabulous.
"Even recently in the street they were saying 'if you are going, then thanks for the last nine years'. That is really touching and it makes me feel that I gave my best for the club.
"I can go with my head held high. I did my best every day in training and in every match, and I left shaking the hand of Arsene Wenger and Mr (David) Dein. That was really important to me."
Vieira's last game was the FA Cup final, when he lifted the trophy after beating Manchester United on penalties.
In previous years the Gunners have voiced their determination to hold on to their star midfielder.
But this summer thay have remained silent and it is thought that they were keen to cash in on the player in order to boost Wenger's summer spending.
Vieira, who had two years left on his Arsenal contract, joins France international team-mates David Trezeguet and Lilian Thuram at Juve.
The Senegal-born star joins Pavel Nedved and Emerson in the Serie A champions' midfield.
The transfer also re-unites Vieira with coach Fabio Capello, who was in charge of AC Milan when they signed the midfielder from Cannes in 1995.
Vieira won the Premiership with the Gunners on three occasions - 1998, 2002 and 2004.
But he was said to be frustrated by Arsenal's continued failure in the Champions League.