The Bournemouth star joined the Italian club in January, with the Serie A side having an option to buy him permanently.
However, he played only 11 games and did not get a single goal or assist in Naples.
Napoli were effusive in their praise of Traore after they confirmed he was departing.
The Italian side, now managed by Antonio Conte, stated: “Our most sincere thanks go for the commitment and professionalism demonstrated during the their time spent in Naples and best wishes for their personal and professional future.”
When loaning out Traore, Cherries head coach Andoni Iraola previously said: “He is one of the players we haven’t found the good combinations of players around him, or a good moment to put him in the starting XI.
“You can’t give the minutes to everyone.”