- Small Business Trends - https://smallbiztrends.com -

Google Warns Site Owners of CSS Error Hurting Their Ranking

google css error

If you are a site owner and have recently received this warning from Google, you are not alone. Here it is:

Google css error

The company has been sending out these Google CSS error warnings to a lot of site owners. The problem is caused by sites blocking Googlebot’s access to CSS and Javascript.

Googlebot is basically the robot that crawls about your website. Googlebot looks for your website’s content and sees how it should rank on the Google search engine.But some sites block Googlebot from seeing CSS and Javascript files.

CSS (Cascading Style Sheet) dictates how your site looks and feels. CSS tells the browser how everything on your site looks, from images to text. Javascript is code that the browser executes to perform extra features, such as hiding or revealing text and playing videos.

The main reason this is happening is a single file, robots.txt. This file dictates what search engines can and cannot see on your site. In the past it was fine to block CSS and Javascript files as Google did not use them.

But in recent years Google has been rendering [1] Web pages more like a typical modern browser, meaning the search engine now uses CSS and Javascript files. So site’s that have blocked these files in the past are now receiving the warning that they may soon see suboptimal rankings in Google Search.

Either your webmaster — or, if you’re brave enough, you — should check out the robots.txt file for your site to see if there is anything in there that would block CSS or Javascript files. Or add the following code to the bottom of your robots.txt file.

User-Agent: Googlebot
Allow: .css
Allow: .js

Google [2] Photo via Shutterstock