Would Google benefit from using web standards?

Google homepage has 5 KB in size and the search results page less than 20 KB. Both pages don’t use standards compliant coding that separates data from presentation. This is not a problem because Google looks the same in all browsers and loads pretty fast. But, what if we used standards compliant code? How should we benefit from that?

Google homepage screenshot

I realized if Google used web standards, than this would be a giant boost to the web standards community (which is, by the way, getting more important every day). What is the benefit to Google? What if I said to you that by using web standards Google could save up to 25% of the HTML file size?

Just a quick note

I wrote this article a few months ago, when I did a research on how would Google benefit from using web standards. I meant to show the final code and look of the page, but in the process I realized that I should read carefully the Google Brand permission of use. So, with this on, I couldn’t use the Google imagery as I wanted to show you how the “new” homepage would look like. Well, I used it for the research purposes when I recreated a homepage and result page, but not for public. What you can read in this article is what learned from implementing standards compliant homepage and result page to Google. Enjoy.

What are web standards?

You have most certainly read about web standards. By using the combination of XHTML and CSS we are separating content from presentation elements. So, how can we popularize XHTML and CSS and how will the people — both the readers and creators of web pages — benefit from implementing this into their webs?

The situation here is not so bright. There is a movement that is strongly for web standards and the other that is opposite. In my opinion, there is no alternative in creating a standards compliant page. By using it you are promoting accessibility (page is viewed on many Internet devices), usability (fonts are scalable, there are options for quickly changing the contrast and look and feel of the page), and helping yourself developing web sites more quickly and with reduced cost.

I decided to make a test wondering how Google would benefit from using web standards. I considered if I could make a homepage and search page that has less size (which means it consumes less bandwidth), that has cleaner code which could be changed easier with CSS, than this would obviously mean there is a prospect in it.

Old VS new

Google is mainly using tables for shaping the content of their pages. But today, we can use structural tags like divisions (DIV) for creating placeholders for content or spans (SPAN) for shaping the content furthermore. For displaying results we could use unordered or ordered lists and every result could become a list-item.

I used a modern web structure to re-create a Google homepage and search results page. I wanted to separate data from styling. My other task was to clean up the code and to use classes to re-use some elements in the page structure. This is best seen in displaying results. Google uses this structure:

Title of the web page

Description of the page …
www.link-to-your-page.com – 42k – CachedSimilar pages

Instead of this, I’m using this one:

What has changed? First of all (it looks prettier :), I used unordered list to display results. In this case list is behaving like placeholder for the results (in our case list-items). Instead of Heading 2 for displaying the title of the web page in results, I used so I could style the title. I could also used Heading 2 or even Heading 3, but I used Heading 2 for displaying the name of the generated search (in our case we are just searching the web) which is displayed on a blue background on top of the results.

I decided that description won’t need its own SPAN so it is a part of the list-item itselft. For displaying the text that shows the link to the page you are trying to reach I used and this also reflects to the last two links — Cached and Similar pages.

With the CSS I styled the class="title" to show the larger font and class="link" to show different link color than the rest of the page.

The challenge behind the job

There were quite many challenges when redesigning any web page including Google. The first one was how to create a home page, and how to position the elements. Search field had to be centered, but the Advanced Search, Preferences and Language Tools link had to be on the right side of it. Now, they are using tables for that, but I wanted to position the links relatively to the form. This is OK, but when I tried to enlarge the fonts, the links were on top of the search field and search button. The max-width:351px solved that.

The second one was how to recreate the paging on the bottom of the results page. The idea behind the paging is that you can click both on the number and on the “O” letter in the Google logo. This looks great and I used unordered list for that. To each list item I gave the fixed width and a top padding that would shift the number on the bottom. With the background positioning I positioned the image depending on the class of the number (if a number is selected I moved the image so the red letter would show up) or the .start and .end classes for the first and last list-item.

Final challenge was how the page will look in different version of Internet browsers. I tested this one in Firefox and IE and I tried to enlarge the text up to 3 times. I had no problem with Internet explorer when enlarging text, but with Firefox I had a problem with the extra links on the right of the search area. I “fixed” this by using CSS-property max-width that will limit the search field to 351px. Second thing I noticed was the problem in IE that for some reason didn’t position the links where they should be. I used different value for IE with conditional comments.

Test results

As I finished the work on the homepage and result page, I took the time to calculate how much KB was saved in the process. In the case of the homepage, we’ve saved almost 1 KB (4,61 KB before, 3,73 KB after), while in the search result page we’ve saved 2 KB (18,2 KB before, 16,3 KB after). This doesn’t seem much, but you should now that I didn’t use any other saving method (like optimizing CSS or the HTML code). What I did is — I used a different syntax to achieve the same thing (i.e. Google used classes for links, and I removed that. I used instead these code to achieve the same thing #main a {...})

You can explore test files here (no images included at this point).
HomepageSearch result page

The conclusion

When talking about web standards, we are almost always taking as advantage that use of web standards produces cleaner and better code. Is there a better place to test the use of web standards than search engines? Should Google use web standards?

I think it should, and it will most certainly be a giant challenge for whoever will work on that. Not just because they can save at least 1 GB of bandwidth on 1 million homepage loads, but because it will be a giant wind in the back of web standards community and it would clearly state – Web standards SHOULD BE USED, BECAUSE THEY HELP TO CREATE A BETTER WEB!

Research parameters

In order to truly recreate the Google homepage and search result page, I used the same links (not the "#" sign) as in the original document. I also used the Google code whenever possible (if not for design purposes), to get the most precise result.

I would like to hear your thoughts on this topic :)


Comments

16 responses to “Would Google benefit from using web standards?”

  1. Great article

  2. Have you heard of these people who calculated how much energy would be saved if the google background were black instead of white? It’s interesting too ;)

  3. jon over at monday by noon did a similar study on google’s homepage, although his results didn’t produce a smaller page like yours have. and don’t underestimate the value of saving 1KB in size for the most trafficked web page on the planet. even 1KB would probably save them tons on bandwidth. good job.

  4. Have you also considered testing on some older browsers? I don’t think the newest versions of IE and Firefox are enough for Google. I haven’t tested it myself, but I’m pretty sure Google works on much older and more obscure browsers. And I’m sure you know how hard it is to make a CSS-based design for such browsers.

    Also, have you tried contacting someone at Google with these results? I’d be most interested as to what their answer would be.

  5. Are there any browsers on this planet that wouldn’t understand current web standards and only the old “standards”, because if there’s a chance of that then Google doesn’t want to have a browser that does not correctly render their site.

    Even though Lynx only shows text and not images it is still correctly rendered for the browser.

  6. @ Janshi
    Yes I heard of this experiment – it’s called Blackle, and can be found here.

  7. @ Chris, Dušan, Dasickis
    When I started to write this article I thought of why would Google change something on his homepage.
    As you mentioned, this homepage looks similar on all the browsers currently in use (even the old ones).
    But, with use of web standards, the code would be easily changed depending on the needs and the homepage would be smaller and faster to download.
    I am not a fan of having 10+ versions of one page depending on a browser, but I think Google should be compatible to these browsers. But, again, wouldn’t it be good to have some nice Standards page for Google Homepage?

  8. I’m sure a standards-compliant Google would be quite nice. But I do believe Google must have some reason not to do it. As to what exactly this reason is… I have no idea. But I have seen quite a few debates on the subject.

    Google, are you reading this? Answers please! :)

  9. @ Dušan
    I think the main reason behind Google’s decision not to use standards-compliant code is the compatibility issue. But I also think that standards-compliant code would be great to see.

  10. As XHTML grows, XHTML 1.0 documents will be able to interoperate among other XHTML documents making it a more browser transitional language.To conclude, using the standards of web development lined out by the W3 is imperative for users to get the most out of a site. Often, making a webpage W3-compliant is the first step of SEO, a marketing tool to get the most out of your advertising dollar.

  11. I completely agree with you. Often, people are asking me about SEO and I tell them that if the page is standards-compliant they are a half-way there.

  12. Pálesz Avatar
    Pálesz

    It would save a lot of bandwith, but the most important thing: it would save a lot of CPU Time. I think. And we know CPU Time = Power, so that would save a lot of power.

    Google, hear us!!

  13. Well, I guess now we know that google isn’t perfect. phew… I was begging to worry…

    But I guess there is no reason for them to have their content SE friendly – because they ARE the search. So half of the value of proper coding is gone.

    Then the other half is that CSS only works on PC’s that that are under 7 years old. Google has to work in countries like peru (Read: using transistors) get the idea?

  14. David, I disagree with you. The point of Google being standards-compliant was not to be SE friendly, but to use less bandwidth as I explained in the start.

    I don’t know how many PC’s are there under 7 years of age, but I think that this shouldn’t be the obstacle for not “evolving”. Or should we all use tables, because this way it would be seen equally by everybody? I don’t think so :)

  15. If the homepage is only 5kb, and all the others are only 20kb tops, there is no benefit to making it smaller. I mean unless your on dial up, who’s complaining about 25kb? I’ve never waited more than 2 seconds for a google result to return. Google is it when it comes to SEO. You go to google to search for something, you find it, then you leave. If something isn’t broke I don’t feel you should fix it. Other sites need google to run through and format them for SEO purposes, google doesn’t need that because it’s the hub for finding any and everything. I don’t feel google or even craigslist for that matter need to be changed at all. They could keep their same look and feel and still be on top of the world. The only thing I found relevant in this article was the comment saying that using less bandwidth = power. other than that all the rest are just opinions by people(me included) no where on googles level. I think they’re done with hooking their search engine up because its perfect, I’d rather them continue creating apps, plugins, and browsers to make my life easier rather than take a step backwards and trying fixing a perfect search engine.

  16. Every now and then I love reading something that designers write about usability, mostly because you’re almost always very very wrong :D

    The reason why Google doesn’t validate is because if you had a valid design it wouldn’t show the same in every browser out there. It is impossible to make a valid HTML and CSS that would actually be seen the same from every browser.

    This was explained in a video by Google’s senior search engineer Matt Cuts, where he explained both why Google doesn’t validate and also why validation is not a ranking factor in SEO. According to that video, it would be more logical for Google to penalize you for having valid HTML and CSS than award you better rankings for it, since if you’re valid, it’s very likely your design doesn’t look right in every browser.

Leave a Reply

Your email address will not be published. Required fields are marked *