Exclude cart from cache

Wordpress LScache Plugin: Exclude cart from cache

Hi, I would like to exclude the cart widget from cache, because it caused issues (clients see cart from other clients). What is the URL to exclude here? Regards, Clara. Hi, you cant just exclude the cart , its part of the page best way is to make it ESI block , but this may requires some custom coding also please provide the report number , you can get it in toolbox -> report -> click send to LiteSpeed I might have an easier option Im surprised by your answer because we used to do it with WP Rocket? Its just about excluding a cookie. Isnt it possible to exclude a cookie? Report number: VAJLAHSN yes , you can do that as well , but that is essentially turn off the cache when that cookie presents in Cache -> Exclude -> Do not cache cookie alternatively , you can use this rule to make cache vary based on cookie RewriteRule . - [E=Cache-Vary:cookie_name] this will be little better as it will create cache based on cookie value , instead of just bypass the cache. but the best way out is either use ajax call or make it ESI. Where should I put this RewriteRule code? Htaccess or Litespeed settings? .htaccess, at top of all dont forget to change the name cookie_name to the actual name