The Risks Involved with robots.txt Mistakes, and Their Fixes

Robots.txt is a utility tool that instructs a search engine crawler on how you want it to crawl on the website.

Its use is highly debated, as its use can either prove to be extremely useful or a massive misfire if you make robots.txt mistakes.

It isn’t as robust as you find it to be, but it can help to prevent your site or server from being overloaded by crawler requests. Also, If you need this crawl block in place on your site, you need to be certain if it is getting used properly.

In this blog, First Rank SEO Services will provide you with a brief explanation of what robots.txt files are, some issues which occur due to a misconfigured robots.txt file, and the impact they might have on your website and your search presence. But you need not worry since we will also be covering the fixes to these issues as well.

What is a robots.txt File?

Robots.txt uses a plain text file format. It is then placed in the root directory of the website. It is mandatory to place it in the topmost directory of your site, and if placed in a subdirectory, search engines will simply ignore it.

Regardless of its power, robots.txt is a simple document and can be created in a matter of seconds using an editor like Notepad.

Common Functionalities of robots.txt Files

  • robots.txt can block certain web pages from being crawled
  • Certain media files can be blocked from appearing in search results
  • Unimportant external scripts, or other resource files, can be blocked

Some Critical robots.txt Issues

Robots.txt files epitomize the fact that with great prospects comes great risk. There are ample issues that a misconfigured robots.txt can give rise to. The critical ones are:

1. Image Files or Blocking CSS from Google Crawling:

Last year, Google stated that disabling Javascript, CSS, or even images counts towards a website’s overall ranking. Google’s algorithm improves with time and is now able to read the website’s CSS and JS code and draw conclusions about how useful the content is for the user searching it. Blocking this content by utilizing a robot file is one of the robots.txt issues which can cause some harm and will not let you rank as high as you expect.

2. Incorrect Use of Wildcards May Lead to De-Indexing of Your Site

Wildcards, symbols like “*” and “$”, are a valid option to block out batches of URLs which you feel have no value for the search engines. Most of the big search engine bots observe and obey by the use of it in the robots.txt file. It is also a nice way to block access to some deep URLs without having to list them all in the robots file.

In case you wish to block, we can say URLs that have the PDF extension, you could write out a line in your robots file with User-agent: googlebot, and disallow: /*.pdf$.

The * wildcard represents all the available links which end with the .pdf, while the $ closes the extension. A $ wildcard at the end of the extension conveys to the bots that only the URLs ending in pdf shouldn’t be crawled while other URLs containing “pdf” shall be crawled.

The Most Common robots.txt Mistakes

  • Robots.txt Incorrectly Placed

Search robots can only work if they are placed in the root folder. This Is the reason why there should only be a forward slash between the .com (or any other domain) of the website, and the ‘robots.txt’ filename, in the URL of your robots.txt file.

If there’s a subfolder, then your robots.txt file won’t be visible to the search robots. To fix this issue, move the robots.txt file to the root directory. Please ensure that you have root access to your server.

This is a common issue with websites that are more than a few years old, since Google has stopped obeying noindex rules in robots.txt files as of September 1, 2019. If the robots.txt file was created before the mentioned date, or contains noindex instructions, then you’re likely to see these pages indexed in Google’s search results.

The solution to this issue is to implement an alternative ‘noindex’ method, an example of which is the robot's meta tag.

  • Sitemap URL Missing

You can add the URL of your sitemap in your robots.txt file, since it is the first place Googlebot looks when it crawls your website.

This is not an error per say, as omitting a sitemap should not negatively affect the actual core functionality and appearance of your website in the search results, but it’ll definitely boost the visibility.


To prevent unwanted effects of a robots.txt file, the most important first step is to correct robots.txt and verify that the new rules have the desired effect. Also, edits for resolving robots.txt issues should be made carefully as mistakes can have a grave impact. It is also recommended to test the changes in a sandbox editor before pushing live.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store


Hi my name is Alina Beth.. I have 3 year experience in Digital Marketing & SEO.