SEO Tip – JavaScript

JavaScript is a very powerful tool for designers and developers alike. There is lots of functionality, and allows you to do a lot of great things within the browser on the client side. But if not used carefully and consciously, you can end up sacrificing your site’s search engine optimization.

  • Storing JavaScript in separate files keeps content closer to the top of the page
  • JavaScript based links or navigation schemes cannot be followed by crawlers. Be sure all links are standard HREFs in anchor tags
  • If JavaScript is used to show or hide different sections of content, there is a good chance that the crawlers may not be able to see it and index it properly
  • If JavaScript navigation is absolutely required, noscript tags should be used to provide content both for users without JavaScript capability, and for the search engine crawlers. A good idea is to put a link to a static sitemap page into the noscript tag, ensuring that your site will be fully indexed. Content within this tag should be used very sparingly, as it has been abused in the past, and overuse could hurt your page rank instead of help.
  • There are lots of other benefits to using JavaScript that are not as much related to SEO a they are good design practices:
    • The site becomes easier to maintain, as the decoration is independent of the actual content copy
    • Better browser caching and server resources

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.