The Frenchman, who left Arsenal for Manchester City in 2011 to win two Premier League titles and a League Cup trophy, has ended his career at age 34.
Nasri served an 18-month doping suspension starting in 2018, an episode that he said changed the way he viewed football.
“One incident really hurt me and changed my relationship with football: my suspension. I found it more than unfair because I did not take any drugs,” the former Olympique de Marseille player told Le Journal du Dimanche.
“It was just a vitamin injection because I was sick,”
After that ban, the midfielder was brought to West Ham by former Manchester City manager Manuel Pellegrini.
His time in East London was far from successful, yet he made only six appearances and did not record a goal or an assist for the Hammers.
Under the leadership of Arsene Wenger at Arsenal, Nasri scored 27 goals in 126 appearances. Nasri’s last club was Anderlecht, where he worked with former Manchester City teammate Vincent Kompany.
Nasri scored five goals for France and played 41 international matches between 2007 and 2013.