views:

157

answers:

5

I would like to know how many web pages on the web are using JavaScript, in percentage.

The metric I'm looking is the number of pages having a <script type="text/javascript"> tag. I'm pretty sure someone (like Google) did studies on that and publish the results !

The goal is to have an idea on how much JavaScript is widespread on the web landscape.

A: 

Check Opera's MOM project, they have that statistic there under "average page". On the phone so can't link now, anyways they developed a web crawler that checkspage structure, not content. I remember the average page has Javascript ,and actuallyhas3 script tags in it

Robert Gould
+6  A: 

This is kind of meaningless: a lot of pages use javascript, but use it in such a way that they degrade gracefully if the scripting is not enabled.

Also, the penetration numbers you cite are both inaccurate and misleading. They don't take into account things like noscript users, smartphones (which often have very buggy javascript implementations) and they don't account for google, which doesn't process your javascript when indexing the site. Also, 95% javascript penetration sounds higher than it is. Taken the other way, at least one person in 20 who visits you site won't have javascript.

Finally, you should consider your audience. You might be developing for a corporate intranet site where you can enforce browser settings and guarantee that number is 100%, or you might be doing a site for the U.S. goverment and be legally required to support screen readers.

Here are some similar SO questions:

Joel Coehoorn
+2  A: 

This is what Robert Gould refers to MAMA: What is the Web made of?

jitter
Thanks! It's MAMA not MOM, my bad.
Robert Gould
A: 

I think it will be around 87% of the total internet visits.

Going by the following estimate.

98% of the IE browsers have JS activated. 13% of the Firefox users have No script installed. Of all the other browsers, 2% will not run JS.

For number of users without JS, this sounds like a reasonable guesstimate. However, I think the OP was asking about pages, not page views (i.e. SO needs JS, Google.com uses JS but works fine without it, etc.)
Piskvor
+3  A: 

Google published Web Authoring Statistics a few years ago. They found then that the script tag was found in roughly half the pages they surveyed in a sample of over a half-billion documents.

Since the web has grown a bit since they did the survey, it's probably safe to invoke the spirit of Carl Sagan, and answer "Billions and Billions!"

Dave W. Smith