You inherit a WordPress WooCommerce store with 3,400 active subscriptions. The previous operator says “renewals just stopped working last Tuesday.” The dashboard shows pending renewals piling up. Customers are not being charged. Failed-payment retry is supposed to be running. Nobody has touched Subscriptions in two months. The triage tree below is the one we walk on takeover.
What’s happening
WooCommerce Subscriptions adds three layers on top of WooCommerce core:
- Subscription objects — stored in
wp_posts(post_typeshop_subscription) orwc_orders(if HPOS authoritative). Each has a billing period, a next-payment date, and a status (active, on-hold, cancelled, expired, pending-cancel). - Renewal orders — generated by Action Scheduler at the scheduled next-payment time. The renewal order is a normal
shop_orderwith metadata linking back to the subscription. - Failed-payment dunning — when a renewal fails, Subscriptions schedules retry actions per the retry rule set (e.g., 3 retries at 24h, 72h, 7d).
Three failure modes account for 80 percent of “renewals stopped working” tickets:
- Action Scheduler is wedged. Pending renewal actions are in the queue but the runner is not picking them up. WP-Cron is disabled but system cron is not running, or the queue is jammed by a different hook.
- Payment method token has expired. Stripe and Square cards expire. The subscription has a stale
_payment_method_tokenand the gateway refuses the charge. The renewal goes to failed-payment dunning, which fails three more times, then on-hold. - Webhook misrouting. The gateway (Stripe, Square) sends a
payment_intent.succeededwebhook for a renewal, but WooCommerce never receives it — typically because the webhook URL was changed during a migration, or a security plugin is blocking the webhook IP, or a CDN is intercepting/wc-api/.
How to verify
# 1. Subscription population by status
wp wc shop_subscription list --format=count
wp db query "SELECT post_status, COUNT(*) FROM wp_posts WHERE post_type='shop_subscription' GROUP BY post_status"
# 2. Pending renewal actions
wp action-scheduler list --status=pending --hook=woocommerce_scheduled_subscription_payment --per_page=20
# 3. Overdue renewal actions
wp action-scheduler list --status=pending --hook=woocommerce_scheduled_subscription_payment \
--per_page=50 --fields=action_id,scheduled_date_gmt | awk 'NR==1 || $2 < strftime("%Y-%m-%d %H:%M:%S")'
# 4. Failed-payment retry actions
wp action-scheduler list --status=pending --hook=woocommerce_scheduled_subscription_payment_retry --per_page=20
# 5. WP-Cron disabled? System cron driving it?
grep -i DISABLE_WP_CRON wp-config.php
crontab -u www-data -l | grep "wp cron"
# 6. Recent failed renewal orders
wp wc shop_order list --status=failed --type=shop_order --per_page=20 --format=table
# 7. Subscription event log for a single problematic subscription
wp post meta list <subscription_id> --format=table | grep -i payment
tail -f wp-content/uploads/wc-logs/wcs-renewal-orders-*.log
# 8. Webhook delivery health (Stripe example)
wp wc webhook list --format=table
# Then in the Stripe dashboard, check webhook attempts for the endpoint
The single highest-signal command is item 3 — the overdue renewal actions. If you see a stack of pending actions whose scheduled_date_gmt is hours or days in the past, the Action Scheduler runner is the failure. If item 3 is empty but renewals are still not happening, the actions are completing but the payment is failing — go to item 7.
The fix
- Confirm system cron is running. If
DISABLE_WP_CRONis true inwp-config.php, there must be a system cron entry runningwp cron event run --due-nowevery minute. Verify withcrontab -u www-data -l. If absent, add it:* * * * * /usr/local/bin/wp cron event run --due-now --path=/var/www/example.com >/dev/null 2>&1 - Drain the Action Scheduler queue by hand. When the queue is wedged, run the AS worker directly to clear the backlog:
Repeat until pending count stops dropping each iteration. Then investigate why the queue grew.wp action-scheduler run --batch-size=25 --batches=10 - Audit payment-method tokens for expiry. For Stripe, a card with
exp_yearin the past will fail on every renewal:
Push the customers with expired cards into the “update your card” flow. Subscriptions ships a customer-facing endpoint for this — link to it from the failed-payment email.wp db query "SELECT post_id, meta_value FROM wp_postmeta WHERE meta_key='_stripe_source_id' OR meta_key='_payment_method_token'" - Re-verify webhook routing. From the Stripe dashboard, send a test webhook to the configured endpoint. The destination must be
https://example.com/?wc-api=wc_stripe(or the equivalent for Square / PayPal). A 200 response with an empty body is the healthy signature. A 404 or 403 means a redirect, a WAF rule, or a security plugin is intercepting. - Tighten the retry schedule. The default 3 retries can leave a subscription on-hold for 10 days. For high-churn-risk subscriptions, reduce to 2 retries at 24h and 96h:
add_filter('wcs_default_retry_rules', function ($rules) { return [ 1 => ['retry_after_interval' => DAY_IN_SECONDS, 'email_template_customer' => 'WCS_Email_Customer_Payment_Retry', 'email_template_admin' => 'WCS_Email_Payment_Retry', 'status_to_apply_to_subscription' => 'on-hold'], 2 => ['retry_after_interval' => 4 * DAY_IN_SECONDS, 'email_template_customer' => 'WCS_Email_Customer_Payment_Retry', 'email_template_admin' => 'WCS_Email_Payment_Retry', 'status_to_apply_to_subscription' => 'on-hold'], ]; }); - Add monitoring on the renewal-action lag. A check that alerts when overdue actions exceed 10 catches this failure before customers do.
The Action Scheduler audit and the cron-handoff articles cover the underlying queue plumbing — pair them with enterprise WordPress hosting operations for the long-term runbook.
Stack Harbor operates WordPress WooCommerce Subscriptions stores end-to-end through the enterprise WordPress hosting practice — the queue, the payment-token rotation, and the webhook routing. If your renewals stopped working and nobody is sure why, we can run the audit.