Joe
Joe

Reputation: 8272

Do search engine bots - crawlers - spiders - etc. have javascript in them?

I don't know how search engine bots work, database entries for robots on my browser records are e.g. Googlebot, msnbot, BingBot, etc.

So I don't know if they have javascript enabled or anything.

Why I want to know if they have javascript enabled? Because I want to require Javascript on my site. What I did to do this is that I have an 'overlay' div with a short message that I set to 'display:none' with javascript on page load. So if there is no Javascript the overlay won't dissapear and nothing in the site is clickable or anything.

So can robots still crawl my site even with the Javascript requirement thing I made? Because I want google and other good bots to be able to crawl my site.

Upvotes: 1

Views: 2126

Answers (3)

mrówa
mrówa

Reputation: 5771

Yes, since 2010 at least googlebot was known for understanding not direct links created in (some) javascript, but they won't need your javascript to read links, as those are plainly visible in html. The same goes with people browsing with javascript turned off.

Upvotes: 3

Peter Bartels
Peter Bartels

Reputation: 1514

As far as I know search engines can parse content recognizing different content and behavior. They can also penalize specific hiding content. I suspect Google is a very smart search engine and has the ability to recognize some javascript but the internal behavior of their system is unknown to us.

Upvotes: 0

AppleDash
AppleDash

Reputation: 1714

Search robots can and will crawl your site, but they do not understand JavaScript, so they will ignore any JS. They should however have no issue crawling the page you described.

Upvotes: 1

Related Questions