[RM_Form id=’3′]
Posted on: Saturday June 20, 2020
Reading Time: 6 minutesFor making your website more searched by others, search engine bots, majorly referred as crawlers or spiders, will come to your website looking for newer texts and link for updating the user search index pages.
Website owners can make search engines to crawl a website in specific ways by using a robots.txt file. Whenever search engine bots come to website, it looks for robots.txt file first and follows the rules next.
The robots.txt file is required to be at base of your site. If your domain was example.com it should be found:
https://example.com/robots.txt
/home/userna5/public_html/robots.txt
One can also create a new file and call it robots.txt as just a plain-text file if you don’t already have one.
Robots.txt file has a common rule that’s based on the user-agent of the search engine crawler. The crawlers use a user-agent to figure out themselves while indexing, here are some common examples:
(a) Googlebot
(b) Yahoo
(c) Slurp bingbot
(a) AhrefsBot
(b) Baiduspider
(c) Ezooms
(d) MJ12bot
(e) YandexBot
Few options are available whenever it comes to restricting your website gets crawled with the robots.txt file. A user-agent: rule specifies which User-agent the rule applies to, and * is a wildcard matching any user-agent.
Disallow: sets the files or folders that are not allowed to be crawled.
Those having 1,000 pages website would be potentially indexed by search engines in a few minutes. But this also causes high system resource usage with all of those pages loaded in a short time period.
A Crawl-delay: of 30 seconds would allow crawlers to index your entire 1,000 page website in just 8.3 hours
A Crawl-delay: of 500 seconds would allow crawlers to index your entire 1,000 page website in 5.8 days
You can set the Crawl-delay: for all search engines at once with:
User-agent: *
Crawl-delay: 30
By default search engines should be able to crawl your website, but you can also specify they are allowed with:
User-agent: *
Disallow:
You can disallow any search engine from crawling your website, with these rules:
User-agent: *
Disallow: /
You can disallow just one specific search engine from crawling your website, with these rules:
User-agent: Baiduspider
Disallow: /
If we had a few directories like /cgi-bin/, /private/, and /tmp/ we didn’t want bots to crawl we could use this:
User-agent: *
Disallow: /cgi-bin/
Disallow: /private/
Disallow: /tmp/
If we had files like contactus.htm, index.htm, and store.htm we didn’t want bots to crawl we could use this:
User-agent: *
Disallow: /contactus.htm
Disallow: /index.htm
Disallow: /store.htm
If we only wanted to allow Googlebot access to our /private/ directory and disallow all other bots we could use:
User-agent: *
Disallow: /private/
User-agent: Googlebot
Disallow:
When the Googlebot reads our robots.txt file, it will see it is not disallowed from crawling any directories.
Do you need an SEO audit for your website? Contact us now!