Title: Disabling Cache for Users
Last modified: August 19, 2022

---

# Disabling Cache for Users

 *  Resolved [lanzilli](https://wordpress.org/support/users/lanzilli/)
 * (@lanzilli)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/)
 * Hello,
 * I’ve tried everything to get recent changes to show to past visitors. New visitors
   see the current & correct version of the site. Any suggestions would be greatly
   appreciated.
 * What I’ve tried:
 * Installed multiple Cache management plug-ins, one at a time. I’ve tried to have
   them cache nothing and also deactivated so that none were active at all.
 * I’ve altered the wp-config.php to include: (‘WP_CACHE’,false);
 * I’ve cleared local cache a million times. Multiple laptops, phones, etc. that
   have been to the site still see the old attributes. New visitors see the correct
   stuff.
 * I’ve fully deleted the old content from the server and even wiped the cache from
   the server itself.
 * Any recommendations would be GREATLY appreciated. WP version is the latest as
   of this post (8/19/22).
 * Thank you in advance!
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fdisabling-cache-for-users%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Moderator [threadi](https://wordpress.org/support/users/threadi/)
 * (@threadi)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15933199)
 * You are currently using the caching plugin “WP Fastest Cache”. Deactivate it 
   and test the accesses again.
 * If it still does not work properly, it is probably due to information that the
   server delivers to the browser regarding caching. You write that you have already
   tested many caching plugins. Therefore look into the .htaccess file, if there
   are any caching entries. An initial WordPress .htaccess file looks like this:
   [https://wordpress.org/support/article/htaccess/](https://wordpress.org/support/article/htaccess/)
 * If you can’t find a solution, contact your hosting support.
 *  Thread Starter [lanzilli](https://wordpress.org/support/users/lanzilli/)
 * (@lanzilli)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15934276)
 * Thank you [@threadi](https://wordpress.org/support/users/threadi/) .. would you
   mind elaborating on “look into the .htaccess file, if there are any caching entries”?
 *  Moderator [threadi](https://wordpress.org/support/users/threadi/)
 * (@threadi)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15934334)
 * Compare your .htaccess file with the one at the link above. More than under the
   link should not be in it if you really no longer have a cache plugin activated.
 *  Thread Starter [lanzilli](https://wordpress.org/support/users/lanzilli/)
 * (@lanzilli)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15934409)
 * Thanks [@threadi](https://wordpress.org/support/users/threadi/). So my .htaccess
   file contains:
 * # BEGIN LSCACHE
    # END LSCACHE # BEGIN NON_LSCACHE # END NON_LSCACHE
 * #BEGIN_ADSTXTMANAGER_HTACCESS_HANDLER
    <IfModule mod_rewrite.c> Redirect 301 /
   ads.txt [https://srv.adstxtmanager.com/13069/saltsugarspice.com](https://srv.adstxtmanager.com/13069/saltsugarspice.com)
   </IfModule> #END_ADSTXTMANAGER_HTACCESS_HANDLER
 * # Use PHP70 as default
    AddHandler application/x-httpd-php70 .php <IfModule mod_suphp.
   c> # suPHP_ConfigPath /opt/php70/lib </IfModule>
 * # BEGIN Really Simple SSL Redirect 5.3.1
    <IfModule mod_rewrite.c> RewriteEngine
   on RewriteCond %{HTTP:X-Forwarded-Proto} !https RewriteCond %{REQUEST_URI} !wp-
   content\/cache\/(all|wpfc-mobile-cache) RewriteCond %{REQUEST_URI} !^/\.well-
   known/acme-challenge/ RewriteRule ^(.*)$ [https://%](https://%){HTTP_HOST}/$1[
   R=301,L] </IfModule> # END Really Simple SSL Redirect # BEGIN WordPress # The
   directives (lines) between “BEGIN WordPress” and “END WordPress” are # dynamically
   generated, and should only be modified via WordPress filters. # Any changes to
   the directives between these markers will be overwritten. <IfModule mod_rewrite.
   c> RewriteEngine On RewriteRule .* – [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
   RewriteBase / RewriteRule ^index\.php$ – [L] RewriteCond %{REQUEST_FILENAME} !-
   f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule
   >
 * # END WordPress
 * # php — BEGIN cPanel-generated handler, do not edit
    # Set the “ea-php74” package
   as the default “PHP” programming language. <IfModule mime_module> AddHandler 
   application/x-httpd-ea-php74___lsphp .php .php7 .phtml </IfModule> # php — END
   cPanel-generated handler, do not edit`
 * Should I delete everything in there and only replace it with that first snippet
   in your link?
 *     ```
       # BEGIN WordPress
   
       RewriteEngine On
       RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
       RewriteBase /
       RewriteRule ^index\.php$ - [L]
       RewriteCond %{REQUEST_FILENAME} !-f
       RewriteCond %{REQUEST_FILENAME} !-d
       RewriteRule . /index.php [L]
   
       # END WordPress
       ```
   
 * What if I also used this:
 *     ```
       # DISABLE CACHING
       <IfModule mod_headers.c>
           Header set Cache-Control "no-cache, no-store, must-revalidate"
           Header set Pragma "no-cache"
           Header set Expires 0
       </IfModule>
       ```
   
 * obtained from: [https://www.a2hosting.com/kb/developer-corner/apache-web-server/turning-off-caching-using-htaccess](https://www.a2hosting.com/kb/developer-corner/apache-web-server/turning-off-caching-using-htaccess)
 * WP Fastest Cache is definitely deactivated. I have Prevent Browser Caching plug-
   in installed and active but suppose to be working to prevent caching, which it’s
   not doing. I’ll probably uninstall.
 *  Moderator [threadi](https://wordpress.org/support/users/threadi/)
 * (@threadi)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15934657)
 * In the code I notice the section of Real Simple SSL. It says something about 
   cache, which I see as a warning signal. The rest is actually inconspicuous I 
   think.
 * You could add that code there. The danger is that this will disable any caching,
   which may make your site slower for visitors. If you want to add it, I would 
   remove Real Simple SSL and add this code, so in sum like this:
 *     ```
       #BEGIN_ADSTXTMANAGER_HTACCESS_HANDLER
       <IfModule mod_rewrite.c>
       Redirect 301 /ads.txt https://srv.adstxtmanager.com/13069/saltsugarspice.com
       </IfModule>
       #END_ADSTXTMANAGER_HTACCESS_HANDLER
   
       # Use PHP70 as default
       AddHandler application/x-httpd-php70 .php
       <IfModule mod_suphp.c>
       # suPHP_ConfigPath /opt/php70/lib
       </IfModule>
   
       # DISABLE CACHING
       <IfModule mod_headers.c>
           Header set Cache-Control "no-cache, no-store, must-revalidate"
           Header set Pragma "no-cache"
           Header set Expires 0
       </IfModule>
   
       # BEGIN WordPress
       # The directives (lines) between “BEGIN WordPress” and “END WordPress” are
       # dynamically generated, and should only be modified via WordPress filters.
       # Any changes to the directives between these markers will be overwritten.
       <IfModule mod_rewrite.c>
       RewriteEngine On
       RewriteRule .* – [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
       RewriteBase /
       RewriteRule ^index\.php$ – [L]
       RewriteCond %{REQUEST_FILENAME} !-f
       RewriteCond %{REQUEST_FILENAME} !-d
       RewriteRule . /index.php [L]
       </IfModule>
   
       # END WordPress
   
       # php — BEGIN cPanel-generated handler, do not edit
       # Set the “ea-php74” package as the default “PHP” programming language.
       <IfModule mime_module>
       AddHandler application/x-httpd-ea-php74___lsphp .php .php7 .phtml
       </IfModule>
       # php — END cPanel-generated handler, do not edit
       ```
   
 * If that doesn’t help either, my recommendation would be that you contact your
   hosting support as already written above.
 *  Thread Starter [lanzilli](https://wordpress.org/support/users/lanzilli/)
 * (@lanzilli)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15954608)
 * Just FYI – The problem was in the name server, not the hosting server. After 
   I flushed the cache there and toggled Cloudflare CDN it was fine.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Disabling Cache for Users’ is closed to new replies.

## Tags

 * [cache](https://wordpress.org/support/topic-tag/cache/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 2 participants
 * Last reply from: [lanzilli](https://wordpress.org/support/users/lanzilli/)
 * Last activity: [3 years, 9 months ago](https://wordpress.org/support/topic/disabling-cache-for-users/#post-15954608)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
