How to enable Leverage Browser Caching in website with .htaccess

Issue

  • How to enable Leverage Browser Caching for my website or server.
  • How to set expiry time for my website contents.
  • How to enabled Leverage Browser Caching for my wordpress / joomla / drupal / django websites.
  • Webpage performance test sites like gtmetrix.com and webpagetest.org reports that Leverage Browser Caching is not enabled on my website.

Environment

  • Website running on Apache web server
  • Website running on cPanel shared hosting

Resolution

Add the following entry in your .htaccess file.
Now go to gtmetrix.com and test your site. You should see 100% gzip compression.

Read : How to enable gzip compression on my website

0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
Scroll to Top