• About
    • History of Dallas SEO
  • Contact
  • Topics
    • Bing
    • Blogging
    • Branding
    • Domain Names
    • Google
    • Internet Marketing
    • Link Building
    • Local Search
    • Marketing
    • Public Relations
    • Reputation Management
    • Search Engine Marketing
    • Search Engine Optimization
    • Search Engines
    • Social Media
    • Tech
  • Advertise
  • Email Newsletter

Bill Hartzer - 2019 Search, Marketing, Tech, and Domain News

Bill Hartzer on Search, Marketing, Tech, and Domains.

names

Home » Google

Google Sends Warnings About Blocking CSS and JavaScript Files

Posted By Bill Hartzer

Google has been very aggressive about sending out warnings in Google Search Console that says that your site is blocking CSS and JavaScript files on your site. Today I received a warning message from Google regarding my site’s blocking of CSS and JavaScript files. But when I first looked at the message, I thought that I wasn’t actually blocking any .CSS or .JS files on my site. Until I looked a little bit further.

Here’s the message I received, July 28, 2015 from Google. Apparently it was so important that Google sent it via the Search Console (formerly Google Webmaster Tools) but they also sent it via email:

Google search console blocking css javascript files

Googlebot cannot access CSS and JS files on https://www.billhartzer.com/
July 28, 2015

To: Webmaster of https://www.billhartzer.com/,

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. These files help Google understand that your website works properly so blocking access to these assets can result in suboptimal rankings.

Here’s how to fix this issue:

Identify blocked resources

Use the “Fetch as Google” feature to identify those resources that robots.txt directives are blocking.

Fetch as Google

Update your robots.txt file

Remove the restrictions on your site’s CSS and JavaScript files from your robots.txt directives and test the changes with the Robots.txt tester. Then update your revised robots.txt file on your site and submit it to Search Console.

Test Robots.txt

Validate the fix using “Fetch as Google”

Fetch and Render your page with the “Mobile: smartphone” option selected to double-check that Googlebot for smartphones renders your content properly.

As an SEO myself, I have been fully aware that you need to make sure that you’re not blocking .CSS or JavaScript files. Typically you do this in your robots.txt file, you can find mine here: https://www.billhartzer.com/robots.txt. That’s where your robots.txt file should be, and where you should find one. If it’s not there, then you need to put one there.

And here’s my robots.txt file, where I don’t appear to be blocking any .CSS or .JS (JavaScript) files:

google search console robots.txt tester

As you can see above, there are no warnings or errors. So it appears that Google sees that I am NOT blocking any .CSS or .js files.

So, if I am not, and have not, been blocking .CSS or JavaScript files, then why is Google sending me a warning message about the fact that my site IS blocking these files? I only have two possibilities here:

1. Google has sent a false message, and they’re wrong. Well, that’s a possibility, they have been before.
2. I am, in fact, blocking a .CSS or .JS file on my site.

Looking into this further, I am blocking access to my wp-admin folder on my site, for security purposes. There in fact happens to be a common.min.js file in that wp-admin folder on the site. So, most likely that may be the culprit.

How did I find this?
Well, I went to google and did this search query: site:billhartzer.com/wp-admin/ which is a folder that I am blocking. Turns out that there IS, in fact, a .JS file there. So I am, in fact, blocking one .JS file. That’s related to a theme that I have installed, so I’ll need to update my robots.txt file so that I don’t block the wp-admin folder. Oh well. So much for security, huh?

Update
So, I went ahead and updated my robots.txt file to allow indexing of the wp-admin folder where the rogue .JS file is located. I could have actually “allowed” indexing of that file, by adding an “allow” command. But for now I’m going to see what effect it has on allowing the whole wp-admin folder to get indexed. I’m pretty confident with the security of my site, so I’m not too worried about allowing that directory to be indexed.

Also, I added the locations of my sitemap files to the robots.txt file, as well. So if you look at my site’s robots.txt file you’ll see those there as well.

Related Posts:
  • 47 TakeAways from Google’s John Mueller’s AMA on Reddit47 TakeAways from Google’s John…
  • Bill Hartzer SEO ConsultantBill Hartzer SEO Consultant
  • 56 Takeaways from Google’s Gary Illyes’ AMA On Reddit56 Takeaways from Google’s Gary Illyes’…
  • Google Penalty Recovery Service by SEO Expert Bill HartzerGoogle Penalty Recovery Service by SEO Expert Bill Hartzer
  • Should You Hire an SEO Consultant or an SEO Agency?Should You Hire an SEO Consultant or an SEO Agency?
  • How to Create a Google Page for Your BusinessHow to Create a Google Page for Your Business

Filed Under: Google, Search Engines

BareMetal web hosting by HostDime

You May Like: Bill Hartzer’s Recent Posts

  • Google Removal Tool to Remove Pages On A Site You Don’t Own February 19, 2019
  • Slideshare Misconfigures SSL Certificate, Causes Downtime February 12, 2019
  • 56 Takeaways from Google’s Gary Illyes’ AMA On Reddit February 11, 2019
  • Wix Promotes SEO in Super Bowl LIII Ad, But Fails with Karlie Kloss Website February 4, 2019
  • What I Learned By Analyzing the Upcoming 2019 NamesCon Domain Auction List January 22, 2019
  • Twitter Fixes their Google Search Result Problem January 11, 2019
  • Using The eufyCam E Wire-Free HD Security Camera January 10, 2019
  • Google to Shut Down Small Business Community from Google January 3, 2019
  • Due Diligence on $750,000 Files.com Domain Name December 19, 2018
  • Grace Millane Case: Google Illegally Revealed Murder Suspect’s Name via Mass Email December 13, 2018
  • Is It Time for an SEO Code of Ethics? December 11, 2018
  • Did a Small Twitter Account Hijack Google Search Result for Twitter? December 6, 2018
  • Google Ads Training Mistake Cost $1.6m in One Hour December 6, 2018
  • Google Loads Maps Results over HTTP December 4, 2018
  • Does Google Prefer Domain Names Registered For a Long Time? November 1, 2018
  • I Upgraded to PHP 7, You’ll Never Guess What Happened October 26, 2018
  • Tech SEO: Conflicting Signals Can Cause Issues October 26, 2018
  • Google Launches .NEW Domains as Shortcuts October 25, 2018
  • Google Expands Dallas Office in Addison, Texas October 24, 2018
  • Use Google Chromecast Streaming Media Player to Stream While Traveling October 9, 2018

DFWSEM logo

Jim & I are the original Founders of the Dallas/Ft Worth Search Engine Marketing Association.

Bill Hartzer is a Brand Ambassador for:



Industry Friends

WTFSEO
SEO By the Sea
WordPress Website Management
Jeff Lenney

Hartzer Consulting

Website and Marketing by Hartzer Consulting.

Connect With Bill Hartzer

Bill Hartzer on Twitter

Bill Hartzer on Google Plus

Bill Hartzer on Facebook

Copyright Bill Hartzer 2001 to 2018.

All product names, logos, and brands are property of their respective owners. All company, product and service names used in this website are for identification purposes only, and are mentioned only to help my readers. All other trademarks cited herein are the property of their respective owners. Use of these names, logos, and brands does not imply endorsement.

Disclaimer – Privacy Policy – Terms of Use

.