Google Blogoscoped

Thursday, August 10, 2006

Google Strict vs Google Deprecated

Why does Google use such deprecated HTML on their homepage? A web page that implements web standards must not be larger, after all, nor does it load slower. (And CSS can be used so it degrades nicely, meaning that say Netscape 3 users might get a gray background instead of a white one.)

Google’s Matt Cutts once argued:

Google’s home page doesn’t validate and that’s mostly by design to save precious bytes. Will the world end because Google doesn’t put quotes around color attributes? No, and it makes the page load faster.

I wanted to see how the Google homepage would fare as XHTML Strict 1.0 along with external CSS and JS files. Here’s the XHTML homepage and there’s deprecated Google gets plenty of traffic, so a couple of bytes add up to larger bandwidth.

I didn’t want to replicate all JavaScript functionality, so in comparison I removed all scripts from both pages. Furthermore, just as Google does, I then removed spacing and such from the files. I end up with a Strict page (HTML + CSS, no JS) of 2.85 K. I end up with Google’s deprecated page (just the HTML, no JS) of 3.08 K. (Furthermore, when we save the logo as PNG instead of GIF and crop it from unnecessary white space, we end up with a 7.87 K image instead of a 8.35 K one.)

But I’m not even saying web standards cause leaner code (they are much easier to maintain for a developer, and that’s why I would suggest them; they also do better on mobile devices and such). It’s probably around the same, and there are different ways to compare file sizes – e.g. I wasn’t religious about removing all white space or using shortest ID names, and on the other hand I also didn’t test the CSS anywhere outside Firefox and IE, so this isn’t a complete test case. What might be more important is that CSS files tend to cache much better, especially when same CSS modules are re-used across the site.

So, I get the feeling Google doesn’t use deprecated HTML on their frontpage ’cause they feel it’s better; it’s just completely deprecated for no good reason other than Google, by and large, not caring too much about web standards.

[Thanks Tony Ruscoe.]


Blog  |  Forum     more >> Archive | Feed | Google's blogs | About


This site unofficially covers Google™ and more with some rights reserved. Join our forum!