gzip
is a file format and a software application used for file compression and decompression. The goal of this article is to provide steps on how to enable gzip compression.
Enabling gzip in cPanel
-
Log into your cPanel account
-
Go to the “Software” section Scroll down until you find the “Software” section on the cPanel home page.
-
Click on “Optimize Website” You’ll be redirected to the “Optimize Website” page.
-
Choose your compression level There are three options:
-
Disabled: This will not compress any content.
-
Compress All Content: This will compress all content.
-
Compress the specified MIME types: This allows you to specify what types of content you want to compress by entering their MIME types. For example,
text/html text/plain text/xml
.
- Save Changes Click on the “Update Settings” button to apply your changes.
NOTE: If you have a website behind Cloudflare, you will likely see Brotli Compression instead of gzip compression. The reason for this is that Cloudflare uses Brotli compression in their setup and when you make a request to a site behind Cloudflare, the response header will come from Cloudflare and not directly from the server.
If you have any questions or encounter issues, please don’t hesitate to reach out to [email protected].