skip to Main Content

If I go to www.google.com and search for something, are the listings pulled straight from the original HTML (“text-only”) page load, or do the listings also account for (i.e. include) any possible front-end CSS / JavaScript stylings/adjustments?

Long version: Consider this basic example and followup questions:

This is me Googling the word "chicken"

  1. If we were a web developer for the Wikipedia (first entry listed) and, for some reason, we changed the word “Chicken” on our page to say “Triceratops” using jQuery (within a standard $(document).ready()), would that listing still say “Chicken” in the title and excerpt below the title, or would it say “Triceratops”? NOTE: Keep in mind that it is possible to do this within <title> inside <head>, or somewhere in <body>.

  2. Similarly, what if we were a web developer for same organization and used some CSS display:none or :after trickery to make it say “Triceratops” instead of “Chicken”, what would this listing say? NOTE: This would probably only apply to places inside <body> since as far as I know, tags like <title> inside <head> are not adjustable via CSS (they are text-only, No HTML).

Related: When will my site's CSS affect my search engine ranking?

2

Answers


  1. This Webmaster blog post states that the web crawler now executes Javascript and renders the page with CSS to have results look closer to what a user would experience it as.

    Today, we’ll talk about our capability to render richer websites — meaning we see your content more like modern Web browsers, include the external resources, execute JavaScript and apply CSS.

    In order to solve this problem, we decided to try to understand pages by executing JavaScript. It’s hard to do that at the scale of the current web, but we decided that it’s worth it.

    Login or Signup to reply.
  2. Here is some tests on indexing after content injection via JavaScript: http://www.centrical.com/test/google-json-ld-and-javascript-crawling-and-indexing-test.html

    Using such technique described in the article you can check if content is indexed in your case.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search