Napoli captain Hamsik, who is the club's all-time leading goalscorer and appearance maker, has been linked with a move to the Chinese Super League for some time, with Dalian Yifang reportedly favourites to secure his signature.
"There are negotiations ongoing, we have to evaluate along with the player," Ancelotti told Sky Sport.
"The club has huge respect for this player, as he wrote history with Napoli, but if he wants to have another experience, we tend to want to make him happy.
"There are talks. We are not hiding anything. As far as I and the club are concerned, if the player wants to try this new experience, we are inclined to give him what he wants."
Hamsik, 31, has been at Napoli for over a decade, having moved to San Paolo at the age of 20 from fellow Italians Brescia in 2007.
Since then the Slovakia international has gone on to make over 500 appearances for the club, scoring 121 goals - both marks historic bests for the southern Italians.
With Hamsik on the pitch Napoli have also lifted three trophies, with the 2014 Supercoppa Italiana adding to Coppa victories in 2011-12 and 2013-14, while he has also helped them to several second-place finishes in the club's most successful period since the heyday of Diego Maradona and Careca in the late 1980s and early 1990s.