Does Google Read Javascript?
-
I would like to include a list of links in a select type box which I would like google to follow. In order to do this, I will be styling it with the help of javascript, and in turn change the select box into a ul and the options into li's. The li's would each contain a link, but if javascript is disabled it will fallback to a normal css styled select box.
My question is would google follow the links made by the javascript? Or would the bot just recognize the select box as a select box and not links.
Thanks for any help!
-
Some additional notes...
Traditionally, Google hasn't followed javascript, but they are getting much better at using it for link discovery.
Just a few weeks ago Matt Cutts made a video in which he recommended making your javascript more readable:
http://www.youtube.com/watch?feature=player_embedded&v=8yTn_HLDaJs
And some evidence in the wild about Google becoming more script friendly:
http://www.webpronews.com/is-googlebot-getting-more-human-like-2012-05
That said, it's still by far better for SEO purposes to ensure that your links are HTML based. Although Google may still discover javascript links, it's unknown what link attributes like anchor text and PageRank pass through them. Best practices, for now, still say to use regular HTML links.
-
Matt says that Google can read some javascript...
Danny Sullivan speculates that they will be able to see those links:
http://searchengineland.com/google-can-now-execute-ajax-javascript-for-indexing-99518
But in my opinion, if you want your links to be seen without a doubt, don't put them in java.
-
I would assume you're talking about using a JS method to create links in the DOM. The answer here is no, Googlebot will not recognize them. Google has improved their ability to read some JS (like if you use an embedded JS link Googlebot can understand that) but it does not interpret or execute JS that I know of.
If you go this route, I would suggest enumerating your links in a noscript block.
-
Google doesn't follow javascript so if you want the links followed on that page you'll need to somehow include them in your code.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Why would Google not index all submitted pages?
On Google Search console we see that many of our submitted pages weren't indexed. What could be the reasons? | Web pages |
Technical SEO | | Leagoldberger
| 130,030 Submitted |
| 87,462 Indexed |0 -
Google Structured Data Problem
Hello everyone, About 1-2 weeks ago, I have implemented rich snippets (microdata) for the product pages of my e-commerce site. However, in the web masters tools, google is saying that the crawlers did not detect any structured data in my site. I have also checked my pages using Structured Data Testing Tool. You can see an example test result in the following address. http://www.google.com/webmasters/tools/richsnippets?q=http%3A%2F%2Fwww.tarzimon.com%2Fproduct%2Fnaif-tasarim-torr-aydinlatma-1031 What may cause this problem? Thank you for your help
Technical SEO | | hknkynr0 -
Website is not indexed in Google
Hi Guys, I have a problem with a website from a customer. His website is not indexed in Google (except for the homepage). I could not find anything that can possibly be the cause. I already checked the robots.txt, sitemap, and plugins on the website. In the HTML code i also couldn't find anything which makes indexing harder than usual. This is the website i am talking about: http://www.xxxx.nl/ (Dutch) The only thing that i am guessing now is the Google sandbox, but even that is quite unlikely. I hope you guys discover something i could not find! Thanks in advance 🙂
Technical SEO | | B.Great0 -
Some competitors have a thumbnail in Google search results
I've noticed that a few of my top competitors have a small photo (thumbnail) next to their listing. I'm sure it's not a coincidence that they are ranked top for the search phrase too. Is this really a help and how can it be done? Many thanks, Iain.
Technical SEO | | iainmoran0 -
Which factors are effect on Google index?
Mywebsite have 455 URL submitedbut only 77 URLs are indexed. How can i improve more indexed URL?
Technical SEO | | magician0 -
Remove Site from Google
How can I get my website out of google? I want all pages completely gone. Thanks!
Technical SEO | | tylerfraser0 -
Penalized by google. How to find out?
Our webpage performs very bad on some keywords relating to one product. At the SeoMoz-ranking page i can se we are number 9 but we have the highest (higher than our competitors) rating in almost every category (at least 25 of 30) on the keyword difficulty report. How do i find out why this is so, or if we have been penalized by google?On other search-engines (yahoo, bing etc) we are number one! And we have the highest pagerank among the competitors...
Technical SEO | | alsvik0 -
How to improve my google backlinks
Hi i have just checked my google back links for my site www.in2town.co.uk and it has said that i have only five, not sure where these are from as the tool i was using did not tell me. But i have looked at my compeditors and they have a few hundred and some have thousands so i am just wondering what i need to do to compete and get more backlinks. I have been writing articles for other sites, free article sites hoping to get some traffic as well as backlinks, for this has not worked out. i just done a report now and i have got the following information DMOZ Directory ? NoYahoo Directory ? NoDigg 0 Yahoo Indexed Pages ? 0 Bing Indexed Pages 0 I would really like to know what steps i need to take as i feel that i have done a lot of good work but my back links are not improving. any help would be great
Technical SEO | | ClaireH-1848860