use strict; my %hash = ( one => 'blah', two => 'echo', thr => 'aaaak', ); my %new_hash = map { ("~foo$_", $hash{$_}) } keys %hash;