Advertise here

How do I prevent robots scanning my site?

Kasomi

JT Founder
The quick way to prevent robots visiting your site is put these two lines into the /robots.txt file on your server:
Code:
User-agent: *

Disallow: /

but this only helps with well-behaved robots

Can I block just bad robots?

In theory yes, in practice, no. If the bad robot obeys /robots.txt, and you know the name it scans for in the User-Agent field. then you can create a section in your /robotst.txt to exclude it specifically. But almost all bad robots ignore /robots.txt, making that pointless.

If the bad robot operates from a single IP address, you can block its access to your web server through server configuration or with a network firewall.

If copies of the robot operate at lots of different IP addresses, such as hijacked PCs that are part of a large Botnet, then it becomes more difficult. The best option then is to use advanced firewall rules configuration that automatically block access to IP addresses that make many connections; but that can hit good robots as well your bad robots.

What if I cannot make a /robots.txt?
Sometimes you cannot make a /robots.txt file, because you don't administer the entire server. All is not lost: there is a new standard for using HTML META tags to keep robots out of your documents.

The basic idea is that if you include a tag like:
Code:
<META NAME="ROBOTS" CONTENT="NOINDEX">
in your HTML document, that document won't be indexed.

If you do:

the links in that document will not be parsed by the robot.
Code:
<META NAME="ROBOTS" CONTENT="NOFOLLOW">
 
Back
Top