Javascript - Clarifying the JS rule in WCAG

Question

Can I please clarify the JS rule? Is it that you must be able to do everything with the JS turned off or just the key things?

Answer

It's all about "accessibility support". In short, JS has enough support across browsers and user agents, including assistive technologies, that it can be relied on to meet deliver content and functionality. This assumes that it is implemented properly and does not introduce accessibility barriers or other WCAG failures — but that's down to what the developer does, not JS per se.

On the other hand, progressive enhancement remains the preferred and promoted approach. There are all sorts of reasons that scripted content and behaviour might not work that have nothing to do with the tech users have. So it's good to plan for failures in the delivery system.

As such, a progressive enhancement approach involves delivering all core content and functionality without JS and Cascading Style Sheets (CSS), then progressively enhancing the experience for users by adding CSS and JS depending on what the users' technology supports.

In other words, a site that relies 100% on JS can meet the Web Standards if it is built properly. But we strongly recommend that sites be built with progressive enhancement instead, and with a mobile first approach to boot.

Last updated