Well mate you can try out the following code in .htaccess file.
<IfModule mod_expires.c>
ExpiresActive On
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 text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"
</IfModule>
Article Source: https://www.cloudways.com/blog/optimize-wordpress-page-load-time-by-browser-cache-leverage
Related Posts:
- Cache policy not updated according to PageSpeed
- browser caching not disabled after disabling in .htaccess
- How can I set Cache TTL for woff and woff2 font files with htaccess?
- Local PC cache stays filled with old WordPress Site data
- Where to put W3 Total Cache rewrite rules in .htaccess? [closed]
- Unable leverage Browser Caching on AWS Bitnami stack (Apache) through W3TC and Cloudfront CDN
- Browser Caching .htaccess
- Improve wordpress security by hiding non public resources
- htaccess rewrite conflict with wordpress rules and ssl
- adding rewrite rules in .htaccess
- Serve apache 404 for missing assets rather then wp 404 template WP_Rewrites
- Remove year and month in URL using .htaccess
- Permalinks not working on second wordpress installed in a subdirect
- Unable to access WP admin
- Move wordpress to folder without changing urls
- Change wp-content without changing the name of the folder
- Using WordPress only for the backend, and using AngularJS as a frontend
- Two domains on one WordPress Installation
- Protect Upload Folder Files With Ampersand Problem
- Which WordPress scripts need to be executable for a fresh installation?
- .htaccess and WordPress Admin Bar
- Keep getting 401 error from WordPress on AWS Lightsail
- Blocking access to wp-login via htaccess not working
- How to Redirect huge numbers of URLs to another URLs?
- Struggling with add_rewrite_rule
- Giving WordPress its own subdirectory – nginx
- Cannot mask WordPress page URL using .htaccess
- need a help for modify .htaccess rule [closed]
- How can I make an htaccess file on a Mac? [closed]
- Restricting user login by IP address
- WordPress overrides custom 404 page with it’s own
- Which is better: 301 Redirect in my .htaccess file or a plugin like Redirection?
- New installation can’t be found due to htaccess of the original non-WordPress site
- Fixing custom 404 pages broken by WordPress in a subdirectory
- Case insensitive header params for API request
- I can’t access the admin panel links as I click it shows 403 error
- 301 Redirect domain Sub-folders to Subdomain subfolder
- Drawbacks to using Options -Indexes
- How to hide login form if basic authentication fails?
- Override 404 page with htaccess
- Htaccess Rewrite reverts to default .htaccess file
- what could cause the htaccess file to be modified?
- change permalink structure with htaccess without SEO impact
- Site in subfolder – all pages work except home
- Can’t upload .htaccess after editing in notepad
- Directing subdomain to main domain and keeping the subdomain format with .htaccess
- Remove /sites/25/ from image URLS
- WordPress – Promoting A Dev Build In A Subdirectory To Production / Root Directory
- How disable canonical redirect wp-signup
- Redirect old domain with query paramaters
- What might be removing my redirects from my htaccess?
- Forcing HTTPS with WordPress on AWS
- WordPress Example Code for Blocking Referrer Spam
- How could a .htaccess with authentication suddenly appear or change?
- WordPress .htaccess to consider blog as directory
- Force non-ssl on WordPress RSS feeds in htaccess, using cloudflare
- Protect wp-login, but get an internal server error
- Local wordpress install only shows home page, all other pages Not Found
- WordPress is rewrite my htacces file. I adding a font rule
- Redirect within wordpress template/plugin
- Redirect wrong links WordPress
- main-domain of wordpress keep redirecting to subdomain
- How to deny access to a particular wordpress site url
- Accepting special characters in querystring
- Centos 7.2 wordpress on going to /admin shows Forbidden You don’t have permission to access /wordpress/wp-admin/ on this server
- Multiple wordpress installations on same server
- Rewrite URL in address bar for a specific page [closed]
- Cannot access subdirectory subpages
- WordPress constantly running out of memory
- Home links redirects to old site
- How can I create a smarter .htaccess file that will add a directory?
- .htaccess found in every folder
- Help with htaccess querystring rewrite
- Configure .htaccess to have a WordPress single site installation with all subdomains pointing to the same pages?
- How do I properly redirect requests to WordPress subdirectory?
- Rewriting subfolders to specific parent folder in WordPress
- Redirect default pagination page to template page’s pagination
- domain redirection is not working from old to new
- Deny,Allow on .htaccess isn’t working
- Using htaccess to prevent spam through wp-comments-post.php
- Remove subdirectory from links
- modifying htaccess for localhost with a custom port
- htaccess- to hide subdirectory slug only from the post
- .htaccess redirects for posts in new directory and new domain
- Fixing Access-Control-Allow-Origin (CORS origin) for multiple subdomains
- domain.in/wp-admin give the result to 403 Access to this resource on the server is denied!
- insert_with_markers() WordPress & htaccess help
- Restrict Content for only Contributors via .htaccess
- Redirect from domain.com to subdomain.domain.com
- MAMP.app & .htaccess – Can’t override after config
- register_post_type and register taxonomy and htaccess
- Cannot find webarh/malware redirect infection that only shows on Chrome
- Why ‘Authorization Required’ is coming on wordpress login
- Restricting direct downloads of wp content files, but allow them on the website.
- Forward blog requests to another URL
- .htaccess rewrite rule stopped working for wordpress site after moving server
- WordPress Media Library rendering blank image tiles
- Subfolder install not working
- Redirect loops in Bing holding my sites back
- Permalinks not working on debian with OVH