Check & Add GZIP Browser Compression

Compressing your content saves bandwidth and improves render time, particular on devices with slow internet connections. Compression allows your web server to provide smaller file sizes that load faster for your visitors. Compression of your HTML and CSS files with gzip typically saves around 50 to 70 % of the file size.

Check if GZIP Compression is active on your website

  1. HTTP Compression test
  2. Check GZIP Compression

Adding GZIP Compression via your htaccess (Apache)

  1. # compress text, html, javascript, css, xml:
  2. AddOutputFilterByType DEFLATE text/plain
  3. AddOutputFilterByType DEFLATE text/html
  4. AddOutputFilterByType DEFLATE text/xml
  5. AddOutputFilterByType DEFLATE text/css
  6. AddOutputFilterByType DEFLATE application/xml
  7. AddOutputFilterByType DEFLATE application/xhtml+xml
  8. AddOutputFilterByType DEFLATE application/rss+xml
  9. AddOutputFilterByType DEFLATE application/javascript
  10. AddOutputFilterByType DEFLATE application/x-javascript
  11.  
  12. # Or, compress certain file types by extension:
  13. <files *.html>
  14. SetOutputFilter DEFLATE
  15. </files>

Adding GZIP Compression on NGINX

  1. gzip on;
  2. gzip_comp_level 2;
  3. gzip_http_version 1.0;
  4. gzip_proxied any;
  5. gzip_min_length 1100;
  6. gzip_buffers 16 8k;
  7. gzip_types text/plain text/html text/css application/x-javascript text/xml application/xml application/xml+rss text/javascript;
  8.  
  9. # Disable for IE < 6 because there are some known problems
  10. gzip_disable "MSIE [1-6].(?!.*SV1)";
  11.  
  12. # Add a vary header for downstream proxies to avoid sending cached gzipped files to IE6
  13. gzip_vary on;

Adding GZIP Compression via a WordPress Plugin

A good candidate is the WP Far Future Expiration Plugin ,which not only activates GZIP compression but adds file expiration for various static file types.
Link

Check speed improvement before and after

  1. GTmetrix
  2. Google Pagespeed
  3. Pingdom Tools
  4. YSlow
Alex

I am a full-stack developer. I love programming,  design and know my way around server architecture as well.  I would never feel complete, with one of these missing. I have a broad range of interests, that’s why I constantly dive into new technologies and expand my knowledge where ever required. Technologies are evolving fast and I enjoy using the latest. Apart from that, I am a peace loving guy who tries to have people around him that think the same.  I truly believe in the principle: “If you help someone, someone will help you, when you need it."

Recent Posts

B&B / Hotel Booking Solutions for WordPress | 2024

BOOKING SOLUTIONS 202x This is my take on a subset of booking, appointment, PMS or… Read More

4 weeks ago

WordPress Cron + WP-CLI + Ntfy

THE GOAL Create a system cron for WordPress, that is accessible and can be easily… Read More

2 months ago

2024 is here and now :)

2024, what's cooking? Slowly getting into the 2024 spirit. 3 projects coming to a close… Read More

4 months ago

2023 ends and whats next !

Short look back at 2023 This has been a busy and interesting year. I am… Read More

4 months ago

cubicFUSION Grid Tweaker – Elementor Grid made easy.

Elementor Pro provides grid containers as an experimental feature. The options provided are limited, when… Read More

5 months ago

Archaeology Travel Booth – Travel Innovation Summit 2023

Archaeology Travel is an online travel guide for people who enjoy exploring the world’s pasts.… Read More

6 months ago