Home » Our Blog » Google Error: Cannot access CSS and JS files due to robots.txt
July 29, 2015

Google Error: Cannot access CSS and JS files due to robots.txt

google error

Have you received this Google error?

This Google error message was sent out through email yesterday: “Google systems have recently detected an issue with your homepage that affects how well our algorithms render and index your content. Specifically, Googlebot cannot access your JavaScript and/or CSS files because of restrictions in your robots.txt file.”

What does this mean and how does it affect your site?

google errorYour site has a robots.txt file, which blocks Googlebots from crawling certain resources on your site. The purpose of these is to give you control over what bots can and cannot see, by excluding the files that do not need to show up in search.

However, the alert is notifying webmasters that certain CSS and JavaScript files are also included in this. This is suggesting that you take the steps to remove this restriction. A quote from the Google Webmaster Blog, “ Disallowing crawling of JavaScript or CSS files in your site’s robots.txt directly harms how well our algorithms render and index your content and can result in suboptimal rankings.”

How can I fix this issue?

If you are running a Drupal site, there may be an item called a “crawl delay” (usually around 10 seconds), that do exactly as they are called – delay Googlebots from crawling your site for a set period of time. Additionally, if you are running a WordPress site, there may be a folder titled “wp–includes” that is blocked.

In the first place, to find out what your robots.txt file blocks is by using the ‘Fetch and Render’ tool in the Webmaster Tools Dashboard. Once you complete the render, click into it and scroll to the bottom. There will be a list of any blocked items.

To fix this, go to your webmaster tools account and open up the robots.txt Tester. Make the changes to your robots.txt, hit submit, click download, and upload that file to your website. Once that’s done, hit submit and Google will be notified that your Robots.txt was updated.

For detailed instructions: https://support.google.com/webmasters/answer/6062598?hl=en

Complete the form to download

Don’t you wish you could pay for your morning coffee with just an email address?

    Congrats on the new ebook
    Thanks for downloading it.

    Digital Firefly Marketing is excited about our collection of eBooks.

    That’s because they are conceptualized, planned and written by us drawing from our expertise and experience. That means you get information that doesn’t just sound good, but has been used to actually help our clients.

    Be sure to check out all of our eBooks and contact us if you’d like help developing your website or building your marketing strategy.

    For now, pour yourself a beverage and tuck into our user-friendly eBooks to learn how you can improve your website’s visibility.

    Visit Our Blog

    No, Thanks. I’ll Check out Later.