Gzip support – Do a need a non gzipped copy of the files?

So I decided to manually gzip all my files on the serrver. Now I wonder if it’s safe to only have gziped files? Or will I for some reason need to have a “non gzipped copy” of the files?

I am thinking about: Browser support, Robots, Google Analytics, anything else you can think of…

Will it be safe to only use:

  • index.html.gz

  • style.css.gz

  • javascript.js.gz

For example:

<a herf="www.domain.com/folder/">link to folder with index.html.gz in it</a>

<script type="text/javascript" src="http://sub.domain.com/javascript.js.gz"></script>

<link rel="stylesheet" type="text/css" media="all" href="http://sub.domain.com/style.css.gz" />

If I put this in my .htaccess file:

AddEncoding gzip .gz
DirectoryIndex index.html.gz


It’s entirely possible that some client comes along that doesn’t support gzip encoded content.

I don’t think any current desktop web browser has that drawback, but other pieces of software could have this: search engine bots (not the major ones, probably), mobile phone browsers, screen reader software, …

By not providing non-gzip variations of all your files you restrict the target audience of your site.

Leave a Reply

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