Endet Sale Product are still shown
-
Hi
We use the WooCommerce shortcode [sale_products columns=3] to show products which are on sale.
The customer normally set a sale price and a start date and an end date.
This always worked fine. But now it does not work anymore since some time.
When the sale ended (actual date is after the enddate) the products are still shown. With the normal price and without the sale badge, but they are still there.
Also with the shortcode [products on_sale=”true” columns=”3″]
We have to remove everytime the sale price, the start date and the end date for that the product is not shown anymore.
Can someone explain and help?
Thanks very much.
Best regards
MikeThe page I need help with: [log in to see the link]
-
Hi @yourchoice,
I understand you’re experiencing an issue where products continue to appear in your sale shortcodes even after their sale end dates have passed, which is definitely not the expected behavior.
This sounds like it could be related to caching or a cron job issue. WooCommerce relies on scheduled tasks (cron jobs) to automatically remove expired sale prices, and if these aren’t running properly, products can get “stuck” in sale status even after the end date passes.
Could you tell me a bit more about your setup? Are you using any caching plugins, and have you noticed if this started happening after any recent updates to WordPress, WooCommerce, or your theme? Also, do you have any other plugins that might be affecting product pricing or sales?
This will help me provide more targeted troubleshooting steps to get your sale shortcodes working properly again.
Looking forward to your response.
Hi @frankremmy
Thanks very much for your response.
I already deactivated all plugins except WooCommerce but this didn’t fix the problem.
The website actually uses no caching plugin. There is only a nginx caching on the server but I think this should be no problem.
Unfortunately I don’t know, since when this problem exists. The customer called me after he saw, that expired sales are still showed on his website.
Do you need more informations?
Best regards
Mike
Hi Mike,
Thanks for the update, that’s really helpful! Since the issue persists even with only WooCommerce active and no caching plugin involved, this points strongly to a WP-Cron issue.
WooCommerce relies on a scheduled task called
wc_scheduled_salesto automatically clear expired sale prices when their end date passes. If this task isn’t running, products remain technically “on sale” in the database even though the end date has passed.Please check the following:
- Go to WooCommerce → Status → Scheduled Actions and search for
wc_scheduled_sales. Is it listed? If it’s showing as past-due or not scheduled at all, that confirms cron isn’t running properly. - In your WooCommerce → Status report, look for the Daily Cron line. Does it show ✔ with a next scheduled time, or ❌ Not scheduled?
- Since you’re running nginx server-side caching, it’s worth checking with your hosting provider whether
wp-cron.phprequests are being blocked or filtered by the nginx configuration. This is a common cause of WP-Cron failures on nginx setups.
Could you also share your System Status Report (WooCommerce → Status → Get system report) at https://gist.github.com? That will show us your WooCommerce and WordPress versions along with the cron status in one go.
Looking forward to your findings!
Hi again
Unfortunately I do not find any secheduled task called wc_scheduled_sales.
But it looks, like the Daily Cron (I think in German this is WordPress Cron) is active.
Here you can download the status report:
https://gist.github.com/maerni/5acc258e362bfaa2dc77b9d676a99a61
The special thing is, that it worked not so long time ago and we didn’t change anything except several WooCommerce updates.
Best regards
MikeHi @yourchoice,
Thanks for sharing the system status.
The problem is more specific: the
wc_scheduled_salesscheduled task that WooCommerce uses to clear expired sale prices simply isn’t being registered at all. Normally WooCommerce creates this automatically, so something is preventing it from being set up.Looking at your active plugins, we’d like you to try one thing first: temporarily deactivate “Discount Rules for WooCommerce” by Flycart and then check WooCommerce → Status → Scheduled Actions again to see if
wc_scheduled_salesappears.The reason is that it directly handles WooCommerce’s pricing and discount system, and given that the issue started appearing around recent WooCommerce updates without any other changes, there may be a compatibility conflict between the newer WooCommerce version and this plugin that’s preventing the sale scheduling task from registering correctly.
If
wc_scheduled_salesreappears after deactivating the Discount Rules plugin, that confirms the conflict and you should check with Flycart for an update or fix. If it doesn’t reappear, please deactivate one by one this time and let us know how it goes.Also, as a quick manual fix in the meantime: go to WooCommerce → Status → Tools and look for “Clear expired transients” and “Schedule expired transient files cleanup”.
Looking forward to hearing what you find!
Hi @frankremmy
I deactivated the plugin Discount Rules for WooCommerce. But also after that the wc_scheduled_sales didn’t come back.
Then I did the quick manual fix, but this also didn’t fix it.
If you like, I can give you a temporary login, perhaps it’s easier to find the problem then?
Cheers
MikeHi @yourchoice,
Thanks for the update and for taking the time to try those steps, I can see you’ve been thorough in testing this and sharing details, which really helps narrow things down.
Just to mention, we did notice your offer to share temporary login access. For your security, we do not and will never ask for any login details on the public forum, and it’s best not to offer or share credentials here. Keeping everything within the thread ensures your site remains safe and aligned with forum guidelines.
Given that the
wc_scheduled_salesaction is still missing even after plugin checks and cleanup, the focus now is to get that scheduled task properly registered again.Here are the next steps I’d recommend:
- Force WooCommerce to re-register scheduled actions
- Go to Plugins → Installed Plugins
- Deactivate WooCommerce
- Reactivate it again
This can sometimes reinitialize missing scheduled tasks likewc_scheduled_sales.
- Manually trigger WP-Cron
- Visit:
https://yoursite.com/wp-cron.php?doing_wp_cron - Then recheck WooCommerce → Status → Scheduled Actions for
wc_scheduled_sales
- Visit:
- Check if WP-Cron is disabled
- In your
wp-config.php, look for:define('DISABLE_WP_CRON', true); - If present, WP-Cron won’t run automatically and needs a server cron job configured
- In your
- Temporarily switch theme
- Activate a default theme like Storefront or Twenty Twenty-Four
This helps rule out any theme-level interference with scheduled actions
- Activate a default theme like Storefront or Twenty Twenty-Four
- Reset WooCommerce scheduled actions
- Go to WooCommerce → Status → Tools
- Run:
- Clear expired transients
- Delete transients
- Then check Scheduled Actions again
You can also review how scheduled actions and cron work here: https://woocommerce.com/document/understanding-the-woocommerce-system-status-report/scheduled-actions/
If after these steps the
wc_scheduled_salesaction still does not appear, the next step would be to check server-level cron handling, especially with nginx, as it can sometimes block or interfere withwp-cron.phpexecution.Let me know what you find after reactivating WooCommerce and triggering cron, that will help us determine the next direction.
Hi @lovingbro
I did/checked all the steps, but the ended sale product is still there.
What I noticed is, that I have actions named “woocommerce_scheduled_sales”. Is this perhaps the same als “wc_scheduled_sales”?
If yes, the last successful execution of this action was like this:
2026-04-14 18:57:48 +0000
Action created
2026-04-15 19:04:00 +0000
Action started over WP Cron
2026-04-15 19:04:00 +0000
Action ended over WP CronWhat I also notices is, that there are over 600 actions named “wc_admin_unsnooze_admin_notes” which failed. They are started about every hour. The error is everytime the same:
“WP Cron action failed: The scheduled action forwc_admin_unsnooze_admin_noteswill not be executed because no callbacks have been registered.”
Could this be a problem?Cheers
Mike-
This reply was modified 2 months, 3 weeks ago by
yourchoice. Reason: missing error message
Hi @yourchoice,
Thanks for the detailed update, that really helps clarify things. I can see you’ve taken the time to go through the earlier steps, and your findings around the scheduled actions are especially useful.
Yes, you’re right,
woocommerce_scheduled_salesis essentially the current equivalent ofwc_scheduled_sales, and based on the timestamps you shared, it is running successfully via WP-Cron. That tells us the cron system itself is working as expected, so we can likely rule that out as the root cause.The failed
wc_admin_unsnooze_admin_notesactions aren’t directly related to product pricing or sale scheduling, so while they’re worth cleaning up at some point, they shouldn’t be causing the sale products to remain visible.At this stage, the behavior you’re seeing, where products are no longer on sale but still appear in sale shortcodes, strongly points to a plugin conflict affecting how WooCommerce determines “on sale” products.
Even though you previously deactivated plugins, I’d recommend running a full plugin conflict test again, just to be certain nothing was missed:
- Deactivate all plugins except WooCommerce
- Switch to a default theme like Storefront or Twenty Twenty-Four
- Check if the issue still occurs
- Then reactivate plugins one by one, testing after each activation
In particular, please pay close attention to Discount Rules for WooCommerce. Since it directly modifies pricing logic, it’s a strong candidate for interfering with how sale products are detected and displayed, especially after recent WooCommerce updates.
If the issue disappears during the test and reappears when a specific plugin is activated, that will confirm the conflict and point us to the exact cause.
Let me know what you find after running through this test, that should help us narrow this down further.
Hi @lovingbro
Just a short question before I do this full plugin conflict test.
As I saw, the woocommerce_scheduled_sales ony runs once a day.
So, do I have to wait after deactivating /activating plugins always one day before I can continue? Or can executed the woocommerce_scheduled_sales manually?Hi there!
I can understand your concern. Let me clarify
The log you posted confirms that
woocommerce_scheduled_salesis running successfully via WP‑Cron on your site. The timestamps you listed (created, started over WP‑Cron, ended over WP‑Cron) show a normal, completed run, so we can safely say the schedule itself is working as expected.Given that, the issue is less about the event not firing and more about how something on the site is affecting which products WooCommerce considers “on sale” for those shortcodes. That’s why the full plugin/theme conflict test is still the key next step here.
However, if you still want to run this task manually, you can use the WP Crontrol plugin to do so. https://wordpress.org/plugins/wp-crontrol/I hope this helps.
Hi
Ok, so I will do the plugin/theme conflict test ad give feedback again.No worries @yourchoice.
Looking forward to your update!
Hi
I deactivated all plugins except WooCommerce.
I switched to the default theme.
I run the action woocommerce_scheduled_sales.
But still the same issue, one product where the sale ended is still there, with the normal price and without the sales badge.
Does a database export help?
Hi there!
Thank you for the update. To assist you further, could you please confirm whether you also disabled the Avia Builder? I can see that you’re using an Avia Builder text block to add the shortcode.
For testing purposes, could you please create a new page, do not enable the Avia Builder on that page, and instead use the default Shortcode block? Then add the sale products shortcode and check if it works for you.
Let us know what you find.
- Go to WooCommerce → Status → Scheduled Actions and search for
You must be logged in to reply to this topic.