After Kaká and Ancelotti left Milan in the summer of 2009, Chelsea tested Milan's resolve by bidding $12 million and Claudio Pizarro for Pirlo.
The club rejected the offer and Pirlo was said to be contemplating a transfer request.
On 5 August, club owner Silvio Berlusconi decided not to sell Pirlo, who said he was overjoyed and wanted to end his career at Milan.
On 21 October 2009, Pirlo scored a notable 30-metre goal in Milan's 3–2 win over Real Madrid in the UEFA Champions League; Milan were eventually eliminated in the round of 16.
Milan finished the season with a 3rd place in Serie A, and a quarter-final finish in the Coppa Italia under new manager Leonardo.

The following season saw Milan dominate the league.
Milan played host to Genoa on 25 September 2010, with Pirlo providing a lifted ball over the top of the defence to set striker Zlatan Ibrahimović free to score the solitary goal of the game.
On 2 October, Pirlo scored a 40-yard goal against Parma to give Milan their first away win of the 2010–11 season.
On 14 May 2011, Pirlo appeared in his last match for Milan, coming on as a half-time substitute for Ambrosini as the club celebrated their Serie A title with a 4–1 victory over Cagliari.
Four days later, Pirlo confirmed that he would be leaving Milan at the end of the 2010–11 season, after a mutual decision not to renew his contract.
In his last season in Milan, Pirlo appeared in the league just 17 times under manager Massimiliano Allegri, notching just one goal and three assists, winning his second Serie A title with Milan that season, also reaching the round of 16 in the UEFA Champions League, and in the Coppa Italia semi-final.

In total with Milan, Pirlo made 401 appearances, scoring 41 goals.
With the club, he won two Serie A titles in 2004 and 2011, as well as two UEFA Champions League titles in 2003 and 2007, also reaching the final in 2005; he also won a Coppa Italia in 2003, a Supercoppa Italiana in 2004, and two UEFA Super Cups in 2003 and 2007, as well as playing a key role in Milan's first ever FIFA Club World Cup title in 2007.
During this period, Milan also finished as runners up in Serie A in the 2004–05 and the 2005–06 seasons, as well as finishing second on penalties in the 2003 Supercoppa Italiana, and in the 2003 Intercontinental Cup.
After Kaká and Ancelotti left Milan in the summer of 2009, Chelsea tested Milan's resolve by bidding $12 million and Claudio Pizarro for Pirlo. The club rejected the offer and Pirlo was said to be contemplating a transfer request. On 5 August, club owner Silvio Berlusconi decided not to sell Pirlo, who said he was overjoyed and wanted to end his career at Milan. On 21 October 2009, Pirlo scored a notable 30-metre goal in Milan's 3–2 win over Real Madrid in the UEFA Champions League; Milan were eventually eliminated in the round of 16. Milan finished the season with a 3rd place in Serie A, and a quarter-final finish in the Coppa Italia under new manager Leonardo.
The following season saw Milan dominate the league. Milan played host to Genoa on 25 September 2010, with Pirlo providing a lifted ball over the top of the defence to set striker Zlatan Ibrahimović free to score the solitary goal of the game. On 2 October, Pirlo scored a 40-yard goal against Parma to give Milan their first away win of the 2010–11 season. On 14 May 2011, Pirlo appeared in his last match for Milan, coming on as a half-time substitute for Ambrosini as the club celebrated their Serie A title with a 4–1 victory over Cagliari. Four days later, Pirlo confirmed that he would be leaving Milan at the end of the 2010–11 season, after a mutual decision not to renew his contract. In his last season in Milan, Pirlo appeared in the league just 17 times under manager Massimiliano Allegri, notching just one goal and three assists, winning his second Serie A title with Milan that season, also reaching the round of 16 in the UEFA Champions League, and in the Coppa Italia semi-final.
In total with Milan, Pirlo made 401 appearances, scoring 41 goals. With the club, he won two Serie A titles in 2004 and 2011, as well as two UEFA Champions League titles in 2003 and 2007, also reaching the final in 2005; he also won a Coppa Italia in 2003, a Supercoppa Italiana in 2004, and two UEFA Super Cups in 2003 and 2007, as well as playing a key role in Milan's first ever FIFA Club World Cup title in 2007. During this period, Milan also finished as runners up in Serie A in the 2004–05 and the 2005–06 seasons, as well as finishing second on penalties in the 2003 Supercoppa Italiana, and in the 2003 Intercontinental Cup.
Andrea Pirlo