Wordpress LScache Plugin: Password Protected Pages In WordPress
Last Updated on: Wed, 15 Apr 2026 00:00:02 Please assist with complete correct configuration settings for the LiteSpeed plugin with password-protected pages in WordPress. Love the product its really fantastic but I must be doing something wrong can someone please help? The first couple of times I enter the password on the front end the page content shows correctly as expected. Then suddenly when I try again at a later stage to enter the password and press submit nothing happens. Only after I purge the cache in the backend then it works correctly and shows the page content, then after a while, the problem starts again. Pretty sure its cache related but not sure what the correct configuration must be so that password-protected pages can function correctly on the frontend with the LiteSpeed plugin for WordPress sites. I now added the following to the .htaccess file RewriteRule . ? [E=Cache-Vary:YOUR_COOKIE_NAME] Do not know if this was the correct fix? It does seem if this fixed the problem, however, the site seems to load very slow sometimes that makes me think it is not cached. So, what I would like to achieve: ? To properly cache the password-protected pages and the page content ? For the password-protected pages to function correctly so that when you enter the password the content displays immediately on the first correct password entry Anyones help will be greatly appreciated. Have a great day! Thanking you in advance for any help! The page I need help with: https://teaching-jobs.co.za/demo-one/ Hi, Did you actually put RewriteRule . ? [E=Cache-Vary:YOUR_COOKIE_NAME] ? try change it to RewriteRule . ? [E=Cache-Vary:wp-postpass_186e16151a69841525d4ddc995dae72d] and purge all Best regards, Hi, Thank you for your quick reply? Yip, I actually put RewriteRule . ? [E=Cache-Vary:YOUR_COOKIE_NAME] but I also think it was in completely the wrong place inside the .htaccess file. I guess you dont know what you dont know ? now? I know thanks! So, I took it out and then added RewriteRule . ? [E=Cache-Vary:wp-postpass_186e16151a69841525d4ddc995dae72d] as instructed. I use Cloudflare CDN so I turned on the Development Mode and then Purged all cache But then it completely breaks the site I also tried to removing RewriteRule . ? [E=Cache-Control:no-autoflush] and leaving only RewriteRule . ? [E=Cache-Vary:wp-postpass_186e16151a69841525d4ddc995dae72d] But it also breaks the site I now removed RewriteRule . ? [E=Cache-Vary:wp-postpass_186e16151a69841525d4ddc995dae72d] and only left the original RewriteRule . ? [E=Cache-Control:no-autoflush] now the site is not broken anymore but I am back to square one? Please help, I hope the above info explains everything correctly? Is there anything else I can try? or is there anything that I am doing wrong? Thanks Maybe this will help here are links to some screen clippings of what I did and the result Screen clipping where I added the suggested RewriteRule to the .htaccess file Screen clipping of broken site after I added the suggested RewriteRule Thanks Hi Did you purge all ? try add that rule at top of htaccess , outside of LSCACHE marker also try disable CSS combine/minify and JS combine/minify , purge all , see how it goes Best regards, Yes, I did clear the cache?nothing helped but then I realized that there was a syntax issue. I copied and pasted your original solution RewriteRule . ? [E=Cache-Vary:wp-postpass_186e16151a69841525d4ddc995dae72d] the dash after RewriteRule . ? was the issue? that caused the site to break? I noticed visually there was a difference in the length old ? new - I replaced it and used your initial suggestion, the site did not break and I have not had an issue again thereafter with a password protected page ? so up to now, I hope it stays the same but so far touch wood the password login seems to be functioning the way you would expect it to function. Thank you so much for your help! I will mark this issue as resolved
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference