Why JavaScript Coders Should Know the Basics of SEO?

Though the major search engines already can crawl plain JavaScript content, most SEOs are still very reluctant to use it on their sites and you need to really know how Google and others treat JavaScript to convince your SEO that it's OK to use the language in that particular case.

In case you really need to use some JavaScript, be sure to run tests with the help of a text browser or just disable JavaScript in yours. That will allow you to see how your content is accessible to Googlebot, which is a text-based browser as well. If you can see searchable content that you deliver with the help of JavaScript, then it's most likely OK and it will be crawled and indexed by search engines.

Some other related SEO and JavaScript articles:
- Does JavaScript Hurt SEO Efforts?
- SEO and JavaScript in Web Development


Sampled by © JavaScriptBank.com

If you want to make a positive impression when you present your project to a panel of SEO guys, you totally need to know how they think about JavaScript, because it will help you to get that job and your knowledge of SEO basics will set you apart.

Back in the days of IE6

The thing is that JavaScript - since it's been introduced with IE6 - has been notorious, because of the fact that it's not SEO-friendly at all. Search engines were not even able to crawl content served by JavaScript. Thus Google literally recommended avoiding JavaScript in websites. As more and more sites start using the technology, search engines will try to catch up with the trends and refine their algorithms. It goes without saying that they will finally make their crawlers read JavaScript where possible.

What is Visible to Search Bots Nowadays?

At the time of this writing, Google can execute some JavaScript (Facebook and Disqus comment, etc.), but only if you keep it as simple as possible. You can use document.write and window.open pretty safely. Unfortunately, we don't know to which extent exactly Google spiders can crawl JavaScript code. Matt Cutts - a guy from Google who usually "discloses" some Google algo secrets - was never too specific about that aspect. Back in 2011, he said: "Google can execute AJAX/JS to index some dynamic comments." The only viable data is obtained from SEOs who actually take the plunge and conduct experiments.

By the way, Matt Cutts is a big authority in the SEO community. So, if you refer to him while proving that your idea is a fabulous one. The best way would be to based your arguments on the articles where Matt talks about JavaScript and SEO. It's a sure-fire way to convince just about every search engine optimization manager. Now let's take a closer look at how to talk to SEOs.

What to Say to an SEO

Though the major search engines already can crawl plain JavaScript content, most SEOs are still very reluctant to use it on their sites and you need to really know how Google and others treat JavaScript to convince your SEO that it's OK to use the language in that particular case.

For starters, you need to emphasize the fact that your .js effects will improve user experience, because it's one of the things that both SEOs and marketers in general really value.

That done, you need to present your technical findings as for how your JavaScript code is absolutely safe in terms of inbound marketing also known as SEO. In order to provide with sound arguments, you need to take the following into consideration.

SEO Friendly Use of JavaScript

Make sure to implement your JavaScript specifically to supplement user experience, but be advised not to use it to render actual content. As a rule of thumb, you need to avoid using JavaScript where possible. Instead, you may want to use both HTML5 and CSS3 which are way more user friendly in many cases.

In case you really need to use some JavaScript, be sure to run tests with the help of a text browser or just disable JavaScript in yours. That will allow you to see how your content is accessible to Googlebot, which is a text-based browser as well. If you can see searchable content that you deliver with the help of JavaScript, then it's most likely OK and it will be crawled and indexed by search engines.

Also, you don't want to use multiple parameters in your code, because it drastically slows down search engines' speed while crawling sites. The slower a search engine bot crawls your site, the less chances to high rankings for your site. So, you should really care about how your code performs in its natural SEO habitat.

As a workaround, you can externalize your JavaScript in an .js file, because it will allow to execute your code way faster. Plus it will make your HTML way less cluttered up.

Befriend an SEO

If you work in a team that has an SEO expert on board, you need to consult with him or her on a regular basis, because it will ensure that you're not working on something that will be rejected after you've worked on it for a few days.

Say, you've got this truly amazing idea to add a super cool effect JavaScript in site navigation (menu buttons). Then you talk to your SEO and he arrogantly gives you a big no-no to that creative idea. The reason is simple: crawlers won't follow any links in JS. And it's just a quick example from many possible issues. Again, if there's a way to do something without JavaScript, do it.

Surprise an SEO

You may make a better impression if you offer a solution to a problem that your SEO did not think to use your services for. The thing is that infographics have been all the rage in the SEO world for a while, but now they are not working that good, because they were overused specifically for the fact that they generated the same anchor text and alt from all sites that embedded them. You could offer enabling dynamic anchor text and alt tag value generation so that the links and alts get as diversified as possible.

Doing so will testify that you're not jus an awesome JavaScript guy or girl, but you're pretty aware of the intricacies of modern SEO.

The Bottom Line

As you probably know by now, most SEOs are really biased as for JavaScript use in their sites, but you can convince them to implement a few cool and SEO-friendly effects (that you'll be paid for) if you are able to show that you're also well versed in terms of technical on-page SEO as long as JavaScript is concerned. If you make that sort of impression at least once, you'll get referrals and consequently more projects, because it's extremely hard to find JavaScript gurus who develop projects with SEO in mind as well.


Author

Kenneth von Rauch is an avid SEO guy who's confident that we can make the Internet a better place to deal with if we create sites with both best web development and SEO practices in mind. He's with WebDesy.com, a site about inbound marketing, web development and everything in between.


This is a guest post, join us NOW to deliver unique, exciting, creative and helpful tutorials, tips and resources to your potential audiences for many benefits.

Language
Translate this page to English Translate this page to French Translate this page to Vietnamese

Recent articles
How to open a car sharing service
Vue developer as a vital part of every software team
Vue.js developers: hire them, use them and get ahead of the competition
3 Reasons Why Java is so Popular
Migrate to Angular: why and how you should do it
The Possible Working Methods of Python Ideology
JavaScript Research Paper: 6 Writing Tips to Craft a Masterpiece
Learning How to Make Use of New Marketing Trends
5 Important Elements of an E-commerce Website
How To Create A Successful Prototype For Your PCB


Top view articles
Top 10 Beautiful Christmas Countdown Timers
65 Free JavaScript Photo Gallery Solutions
Adding JavaScript to WordPress Effectively with JavaScript Localization feature
Best Free Linux Web Programming Editors
16 Free Code Syntax Highlighters by Javascript For Better Programming
Top 10 Best JavaScript eBooks that Beginners should Learn
Top 50 Most Addictive and Popular Facebook mini games
More 30 Excellent JavaScript/AJAX based Photo Galleries to Boost your Sites
Top 10 Free Web Chat box Plug-ins and Add-ons
The Ultimate JavaScript Tutorial in Web Design


Free JavaScript Tutorials & Articles
at www.JavaScriptBank.com