September 30, 2019
3min Read
Irfan F.
Do you want to make your site faster, increase SEO ranking, and attract more traffic? You can do it all by compressing your web files using the GZIP file format. Your website will take less space, and site speed might be improved.
Sounds interesting? Read on to find out how to enable GZIP compression on your site.
GZIP compression is a popular method used to reduce the size of web files — including HTML, CSS, PHP, and JavaScript. That way, your site speed will improve, since visitors will download the compressed data instead of the full-sized files.
What’s more, Google includes page loading time as one of the factors in its ranking algorithm. The faster your site loads – the higher you’ll rank.
Considering the benefits of GZIP compression, it’s important to check whether your site has enabled it or not. You can use the Check GZIP Compression tool to do so.
If GZIP is already activated, the tool will show you the page size before and after the optimization. If it’s not, an error message will appear.
There are two methods of enabling GZIP compression: modifying the .htaccess file or using a WordPress plugin, like WP Rocket.
The easiest way to enable GZIP compression in your WordPress site is to install a plugin. It will be a lot easier and safer than modifying the .htaccess file.
There are a lot of plugin choices available, but we have singled out these three plugins based on their features and ease of use:



Since these plugins can do so much more than enabling GZIP compression, I suggest that you try all of them to see which one fits you best. After all, they are free and frequently updated, what’s not to love?
This method is quite technical, so it’s more suitable for advanced users. However, anyone can do it as long as they are careful.
Before we continue, remember that you should always back up your .htaccess file first in case something goes wrong.

<IfModule mod_deflate.c> 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 </IfModule>
Now, if you use the Check GZIP Compression tool again, the results should look like this:

GZIP compression reduces the size of your pages and speeds up your site. As a result, visitors will have a great user experience and your site can rank well in SERP.
You can easily enable GZIP compression on your site by using two methods: either installing a WordPress plugin or editing the .htaccess file. Here’s a summary on how to do that:
Pretty easy, right? Let us know in the comments if you have any questions!
Leave a reply