Should your website work without JavaScript

Coming back more than 10 years later, it's worth noting my first two bullet points have faded to insignificance, and the situation has improved marginally for the third (accessible browsers do better) and fourth (Google runs more js) as well.


There are a lot more users on the public internet who may have trouble with javascript than you might think:

  • Mobile browsers (smartphones) often have very poor or buggy javascript implementations. These will often show up in statistics on the side of those that do support javascript, even though they in effect don't. This is getting better, but there are still lots of people stuck with old or slow android phones with very old versions of Chrome or bad webkit clones.
  • Things like NoScript are becoming more popular, so you should at least have a nice initial page for those users.
  • If your customer is in any way part of the U.S. Goverment, you are legally required to support screen readers, which typically don't do javascript, or don't do it well.
  • Search engines will, at best, only run a limited set of your javascript. You want to work well enough without javascript to allow them to still index your site.

Of course, you need to know your audience. You might be doing work for a corporate intranet where you know that everyone has javascript (though even here I'd argue there's a growing trend where these sites are made available to teleworkers with unknown/unrestricted browsers). Or you might be building an app for the blind community where no one has it. In the case of the public internet, you can typically figure about 95% of your users will support it in some fashion (source cited by someone else in one of the links below). That number sounds pretty high, but it can be misleading; turn it around, and if you don't support javascript you're turning away 1 visitor in 20.

See these:

  • https://stackoverflow.com/questions/121108/how-many-people-disable-javascript
  • https://stackoverflow.com/questions/822872/do-web-sites-really-need-to-cater-for-browsers-that-dont-have-javascript-enabled>

You should weigh the options and ask yourself:

1) what percentage of users will have javascript turned off. (according to this site, only 5% of the world has it turned off or not available.) 2) will those users be willing to turn it on 3) of those that aren't willing to turn it on, or switch to another browser or device that has javascript enabled, is the lost revenue more than the effort to build a separate non-javascript version?

Instinctively, I say most times the answer is no, don't waste the time building two sites.