use URI::Escape; my $x = '%3Cb%3Eyo%3C%2Fb%3E'; print uri_unescape($x);