use LWP::UserAgent; $ua = LWP::UserAgent->new; $ua->agent("$0/0.1 " . $ua->agent); # $ua->agent("Mozilla/8.0") # pretend we are very capable browser $req = HTTP::Request->new( GET => 'http://www.baidu.com'); $req->header('Accept' => 'text/html'); # send request $res = $ua->request($req); print $res-> More