Webmasters Stack Exchange is a question and answer site for pro webmasters. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

One of my sites lives on GoDaddy's bottom-of-the-line cheap hosting, I have the correct code in my .htaccess file, but it's not compressing because mod_deflate is not loaded.

How do I enable that?

The best I've found is an article on GoDaddy which suggests I use PHP to zip everything (which is going to be more work than just changing hosting companies):

Add the following code to the very top of your Web pages above the DOCTYPE:

if (substr_count($_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip')) b_start("ob_gzhandler"); else ob_start();

share|improve this question
Just to add some results, the shared hosting does not seem to be able to take a lot of traffic. I host my wordpress blog there to keep my real sites safe, and under a few thousand visitors an hour the server is accessible maybe 50-70% of the time. – Dave Mar 22 '11 at 17:22

I know this is an old question, but it shows up early on google so I thought I would answer it. You can now enable gzip on GoDaddy by adding the following to the .htaccess in your root directory.

AddOutputFilterByType DEFLATE text/text text/html text/plain text/xml text/css application/x-javascript application/javascript

Source - GoDaddy Support

share|improve this answer

Since you have a shared hosting account there is no way to add mod_deflate since it requires making changes to Apache which you are not allowed to. So your options are to either switch hosts or use the PHP solution godaddy suggests.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.