Perl treats file names as opaque strings of bytes. readdir doesn't decode the names it returns, and File::Find doesn't decode the names returned by readdir. That means you're encoding a string that's already encoded. Either decode the file name from find before printing it, or don't encode the file name on print.