Gzip compression is a really easy way to boost the speed of your website and save bandwidth. It works by serving a really small version of a text-based files if the browser is capable of handling them.
As illustrated by the below example, it can make a huge difference. Using a css file of 66.7KB in it’s normal form, you can see how it’s compressed down to just 11.KB (a reduction of nearly 83%!). The knock-on effect of this is a total page load of just over 1.5 seconds, and with loading speed becoming an SEO ranking factor, it’s definitely worth integrating.
Very little web development skill is involved for this one. There are a few ways to implement it depending on server and website setup, though taking a WordPress website hosted with us as an example, we simply add the following to the root .htaccess file:
# BEGIN GZIP
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
# END GZIP
This uses the mod_deflate Apache module and simply instructs which filetypes are to be compressed.
Once the above is implemented, you can use a site like checkgzipcompression.com to check the gzip compression is working.
Interested to find out how we can improve and optimise your website?
Drop me an email or give the studio a call to find out more…
Lead Web Developer | Designer