in reply to How to save in UTF Mode

To save a file as UTF-8, open the file handle with open my $handle, ">:encoding(UTF-8)", $filename or die ....

This also works for other encodings.

See also perluniintro, perlunicode and Encodings, Unicode and Perl.

(Update: fixed reading/writing direction in the open mode, thanks to ikegami++).