Contact us today to unlock your website's true potential

Enabling gzip Compression

Post image for Enabling gzip Compression
Instant gratification is not good enough for us now; we need things before we know we want them (this is something Google does well!). Waiting is becoming foreign to our nature, at least insofar as our online lives go. Speed is a must for websites to convert visitors. Google experimented and slowed down its SERP from 100 to 400 milliseconds. This is less than half of a second, but it resulted in .2 to .6 percent fewer searches. The longer people were exposed to the slower conditions, the fewer searches they conducted. Speed matters. It matters to Google, and it matters to your site. Enabling gzip compression is one step in making it leaner and meaner.

First, what is gzip? It is a compression method that works by finding similar strings – such as whitespace, tags, etc., in a text file. It replaces those (temporarily) and makes the file smaller.  Smaller sites = faster page load times. About 90 percent of sites support gzip, and it can reduce response size by 70 percent.

  • Your host may be compressing your HTML documents – it’s not likely, but it could be. You can use GIDZipTest to check.
  • If it is not being compressed, you’ll need to know two things: what server you are running and how to access your web server configuration. If it’s Apache (like it is for 64 percent of active websites and the most heavily used in the UK), simply edit the .htaccess file and add:

# compress text, html, javascript, css, xml:
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
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
# Or, compress certain file types by extension:
<files *.html>
SetOutputFilter DEFLATE
</files>

And that is it. You have enabled gzip and have reduced your load times. This is just one way to speed up your sites, and we’ll explore more in the coming weeks!

address

Address

SEO.co.uk, Devonshire House, 84-88 Pinner Road, Harrow, HA1 4HZ

Enter Your Details Below