It is a txt file created for robots by the webmasters to direct web robots how to crawl through web pages of a website. These robots are used by search engines to crawl on websites, search engines use their robots to crawl through websites as to seek whether sites follow the standards and also to index pages content, these robots also help search engines to store data into their databases. Robots.txt file is a part of Robot Exclusion Protocol (REP), a group pf web standards which instructs robots how to crawl through web. These robots are called out by various names by their search engines like:

  1. GoogleBot by Google
  2. Baidu Spider by Baidu
  3. MSNBot/BingBot by Bing
  4. YandexBot by Yandex
  5. Soso Spider by Soso
  6. ExaBot by 3ds
  7. Sogou Spider by Sogou
  8. Google Plus Share by Google
  9. Facebook External Hit by Facebook
  10. Google Feedfetcher by Google

The crawl function is there to “allow” or “disallow” bots to read all the sections or particular sections of a website. This function helps webmasters to save themselves from badbots, badbots are generally spammers, email crawlers, etc., these bots are used to steal information and spam the sites.

Basic format:

User-agent: [user-agent name]
Disallow: [URL string not to be crawled]

With these two lines together it is considered as complete robots.txt file. A robot file can contain multiple lines of omg user agents and their directives.

Blocking web crawlers from all the content of website:

User-agent: *
Disallow: /

Allow web crawlers for all the content

User-agent: *

Block a crawler for particular content:

User-agent: *
Disallow: /example-subfolder/
Blocking specific bot from crawling the website:

User-agent: Badbot
Disallow: /

Blocking crawler from visiting specific page of website:

Disallow: /example-subfolder/blocked-page.html

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Click to Call
(+91) 9871 430 039