If your server is Apache (most web servers), you can use the ‘ExpiresDefault’ directive to set an expiration date relative to the current date.
ExpiresDefault "access plus 2 months"
This sets the expiry date of the file 2 months into the future from the current time. The following values can be used to specify the time period:
eg. ExpiresDefault “access plus 14 days”
How to Add Far Future Expires Headers to WordPress Blog
ExpiresDefault "access plus 2 hours"
# Expire images header
ExpiresByType image/gif A2592000
ExpiresByType image/png A2592000
ExpiresByType image/jpg A2592000
ExpiresByType image/jpeg A2592000
ExpiresByType image/ico A2592000
ExpiresByType text/css A2592000
A2592000 means 1 month in the future (606024*30=2592000)
According to Wikipedia – “An ETag (entity tag) is an HTTP response header returned by an HTTP/1.1 compliant web server used to determine the change in content at a given URL. When a new HTTP response contains the same ETag as an older HTTP response, the contents are considered to be the same without further downloading.”
ETags were added to provide a mechanism for validating entities that is more flexible than the last-modified date but If you’re not taking advantage of the flexible validation model that ETags provide, it’s better to just remove the ETag altogether. Removing the ETag reduces the size of the HTTP headers in the response and subsequent requests thus improving site performance.
Add the following to your .htaccess file to remove ETags:
These tweaks can dramatically improve the performance of your site even though they are minor and doesn’t take that long to apply. I have seen a 20% speed improvement on my page loads just by adding these tweaks.
Hey, Friend feel free to comment here about How to Add Far Future Expires Headers to WordPress Blog.