Wordpress LScache Plugin: LSCache Issue with WooCommerce
Last Updated on: Wed, 15 Apr 2026 00:00:02 Hello, I have a customer who has LightSpeed Enterprise with WooCommerce installed. Users who are not logged in, everything works great and cached pages are served. When a user logs in, there is no caching. Looking at the logs, I see a message that says this: [Ctrl] X Cache_control -> no Cache ( 3rd party woocommerce not cache due to has wc notice ) => LiteSpeed Control::set_nocache(( 3rd party woocommerce not cache due to has wc notice ))@362 => WP_Hook->apply_filters(,ARRAY)@287 => WP_Hook->do_action(ARRAY)@311 HTTP response header shows this: x-litespeed-cache-control: no-cache,esi=on Any idea how to solve this so that logged in users get cached pages? Thanks in advance! Hi, It should only first time access got no-cache which is due to setting vary , after that it should be cached please try refresh a page once or twice , you should see it get cached. also make sure you have enabled cache login user Best regards, Hello! Ive generated a report to help us out here: ZXHBLYWG After refreshing the page multiples times, the headers still indicate x-litespeed-cache-control: no-cache,esi=on. I have Cache Logged-in Users disabled because I want to publicly cache the pages using the vary groups, not cache all pages privately for each user. This worked until recently, not sure when it stopped working. Let me know if that helps. I think if we could track down the reasoning for the 3rd party woocommerce not cache due to has wc notice message in the Litespeed debug logs that might help. Jake Your username looks familiar Do you still in Slack ? Thanks for the helpAfter researching together, we discovered that the cause was a Woocommerce backend message that was preventing the admin user (not subscribers) from receiving cached pages on the front end. After dismissing the Woocommerce alert in /wp-admin/, the pages were cached for my admin user as normal. References: https://github.com/litespeedtech/lscache_wp/blob/cd965b22668a6c59b96fd3a4066251ebe991fd9d/thirdparty/woocommerce.cls.php#L610 https://woocommerce.github.io/code-reference/files/woocommerce-includes-wc-notice-functions.html Hello, I have the exact same problem: I have a woocommerce website, for any logged in user the pages are not cached and if I check the logs I have: [Ctrl] X Cache_control -> no Cache ( 3rd party woocommerce not cache due to has wc notice ) => LiteSpeed Control::set_nocache(( 3rd party woocommerce not cache due to has wc notice ))@362 => WP_Hook->apply_filters(,ARRAY)@292 => WP_Hook->do_action(ARRAY)@316 I need help because I dont understand what is the actual solution. Thank you. I dont believe the issue has been addressed yet. I recently had this pop up again, but was unable to determine which wp-admin Woo alert needed to be cleared to allow caching? So no caching for that site which is crazy! I resolved this by commenting out a few lines of code in the following file: ?/wp-content/plugins/litespeed-cache/thirdparty/woocommerce.cls.php / elseif ( function_exists( wc_notice_count ) && wc_notice_count() > 0 ) $err = has wc notice / In my opinion this is a really bad idea. In many cases, there is no way to find the notices that need to be cleared, so no logged in users receive any cached pages indefinitely which obviously cause huge performance issues and makes LS Cache useless. @CacheCrawler, Obviously when I update Ill have to implement this code change again. Is there any way that this can be addressed?
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference