WordPress leverage browser caching rules that are adding into .htaccess file in available in root folder. These rules helps to download and cache the static file content into browser for specific time period. Thus next time when SmartGeekBlog is visited, the major chunk of static files are retrieved from browser cache that are already available. This helps in loading the website faster with minimum file request.
Leveraging via .HTACCESS plugin
Locating the .htaccess file is very simple. If you are using WordPress SEO plugin, then under WordPress SEO go to Tools > Edit Files, you will have Edit the content of your .htaccess add the caching rules and click on update.
Other way of locating .htaccess file in checking in WordPress root folder. If your hosting provided have hidden .htaccess file, then while browsing through File Manager select the checkbox Show Hidden Files. .htacess file will be available in file manager browser.
Note: Rules should be added at the top of any others rules already present in .htaccess file.
Following are the browser caching rules for keep static files in cache memory:
## EXPIRES CACHING by SmartGeekBlog.com ##
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 10 days"
## EXPIRES CACHING by SmartGeekBlog ##
You can check the performance of leverage browser caching rules by using Google’s PageSpeed and YSlow! tools.
Browser Caching using WordPress Plugin
One of the best caching plugin with many features like caching, CDN integration (like MaxCDN) that will speed up your website performance.
An extra plugin which is only used for enabling browser caching.
Note and Conclusion:
Make sure that mod_rewrite is enabled in your Apache web server, if not then contact your web server technical team to get it enabled as rewrite module will be needed for completing caching action.