08 May 2012

Is Your HTTP Compressed?

It’s been just over two years now that Google announced that page load speed was added to their list of significant Page Rank criteria. The deal is simple: all other things being equal, the webpage that consistently loads more quickly will earn the page rank lift.

Of course, there are many factors that can affect page load speed. Some things you can’t directly affect (other than selecting a different hosting service provider in which case sites like this may help), but many factors that influence page load speed are directly manageable by you. Here’s a quick (but not comprehensive) list of variables that affect page load speed:

Server factors:

  • Server host capacity and processing speed
  • Host network pipes capacity
  • DNS server speed
  • Number of router hops
  • Server caching enabled
  • HTTP compression enabled

Webpage factors:

  • Use of images (quantity, size, if images are scaled on the fly, use of CSS sprites)
  • Use of JavaScript & CSS (minified code, location within file (CSS in <head>, JavaScript at end of page), use of internal code vs. external files, quantity of files)
  • Use of large rich Internet application (RIA) technology files, such as Flash or Silverlight
  • Use of media files (videos, audio, PDF content, quantity)
  • Number of HTTP requests made
  • Character set specification (UTF-8)
  • Serving unused CSS content

Client factors:

  • Computer processing speed
  • Network connection speed
  • Browser choice and configuration (especially if it’s loaded up with plugins and add-ons)
  • Support for HTTP compression

You can learn more about the page load speed factors you can influence from the Google Developers post called Web Performance Best Practices. The Yahoo Developer team also produced a useful post on the topic called Best Practices for Speeding Up Your Web Site. I recommend reviewing them both for ideas and approaches to optimizing the page load speed of your site.


Testing page load speed

So do you know how fast your site speed is today? If not, you need to run the free SEO tool by Internet Marketing Ninjas called Load Time Speed Test Tool. Scanning your webpages with a page speed test tool is a smart way to identify problems that might be holding back your site from optimal page rank performance.

Before you run off and make any changes to your site, however, first run the tool to get a baseline result. By identifying each object on the page to be downloaded and noting the time taken to download each item, the tool will reveal potential opportunity areas for optimization (such as overly large images, slow objects, numerous JavaScripts and/or CSS files, etc.). Consider the tool’s baseline results to be your roadmap for attacking the load speed issue for your pages.

Then, after optimizing the areas brought to your attention from the information contained in this post, rerun the Load Time Speed Test Tool to see how much of a difference you’ve made.


Check on HTTP compression

One of the most important elements I want to cover here for improving page load speed is HTTP compression. A Google developer article written in 2009 claimed that every day, the equivalent of, “more than 99 human-years are wasted because of uncompressed content.” Working with uncompressed website content data consumes more network bandwidth, which means it takes more time to serve and download – perhaps doubling, tripling or taking even more time (compared to working with compressed data on the same sites). The worst thing is that this doesn’t have to happen!

The beauty of using HTTP compression is that once it’s enabled on the server, it works automatically for HTTP compression-compatible browser clients. There’s nothing else you need to do to your site’s pages to see the benefits of HTTP compression, such as saving bandwidth, reducing download time, and positioning your site to begin earning higher page rankings.

Who uses HTTP compression?

Pretty much all modern web browsers (by modern, I mean the current releases of Firefox, Chrome, Internet Explorer, Opera, RockMelt and Safari, even Safari on IOS) are compatible with at least some forms of HTTP compression. In addition, all current web servers typically support HTTP compression as well.

How does it work?

When a modern web browser sends an HTTP request to a web server, the browser identifies which forms of HTTP compression it supports (Gzip is the most common compression technology used). If the web server supports any of the browser’s compression technologies, it typically responds to the HTTP request by compressing the data it sends.

While there is a small bit of latency added on both the server side for data compression and the client side for data decompression, the net effect of using HTTP compression on bandwidth and time savings typically results in a substantial net improvement in page load speed. Even busy web servers achieve a net benefit in processing overhead by using HTTP compression due to the reduction of processor requirements in serving less data per connection.

How do I know if my website supports HTTP compression?

There are several testing sites you can use. I have found HTTP Compression Test to be very useful. Navigating to this page initially tests the browser you used to visit the site to determine if it is Gzip-compatible. Hopefully like me, you’ll see the green message as shown below:

Web browser results for HTTP compression compatibility test
The page contains a text box in which you can type or paste the URL of the page you want to test. Add the URL and then click Test. Again, getting green test results are a good thing:

Web server results for HTTP compression compatibility test

Note in the above results the data savings result achieved thanks to HTTP compression!

If your testing reveals that your web server does not have HTTP compression enabled, change that! If you use either IIS or Apache as your web server platform (and most people do), check out the specific instructions for enabling HTTP compression listed at Need for Speed – Enable HTTP Compression. To enable HTTP compression on other platforms, refer to your server documentation.

Page load speed is yet another important criterion to manage for optimizing your site for page rank in both Google and Bing. Ensuring that HTTP compression is enabled is nearly a freebie benefit, so be sure to take advantage of the technology to speed up your site. Not only will your site visitors appreciate it, so will the search crawlers!