Configuring Apache to use mod_expires

mod_expires it will caches the page content to the visitors temporary files it may reduce on your Server from High Bandwidth Usage & also the files transferring load

the following is code where you can put into your .htaccess if you we Web Host Customer
or if you are a Server Administrator and want to apply the Mod_expires to all hosts please copy & paste the following to /usr/local/apache/conf/httpd.conf

<IfModule mod_expires.c>
# turn on the module for this directory
ExpiresActive on

# cache common graphics for 7 days
ExpiresByType image/jpg "access plus 7 days"
ExpiresByType image/gif "access plus 7 days"
ExpiresByType image/jpeg "access plus 7 days"
ExpiresByType image/png "access plus 7 days"

if you want to verify that you have mod_expries installed run from your ssh as root the following

httpd -l
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

[cPanel] Fix Bandwidth Logs on all users

To run/fix all users Web logs (Bandwidth Fix) run the following command from root SSH...

Fix for Munin MySQL Monitoring Plugin Graph Not Showing or Blank

through WebHost Manager (WHM) has added the Munin Service Monitor as easily installed plugin to...