Stripe payments or webhooks fail
Work through these in order. Most Stripe problems are keys for the wrong mode, or a webhook that can’t reach your site.
1. Test the connection#
On Settings > Subscriptions > Stripe, click Test connection. A failure means the keys are wrong or for the other mode: test keys (pk_test_, sk_test_) work only in Test mode, live keys (pk_live_, sk_live_) only in Live.
2. Check the webhook#
In Stripe, check the webhook:
- points at the address Nahnu Links shows, like
https://yoursite.com/wp-json/nl/v1/stripe/webhook; - sends
payment_intent.succeeded,payment_intent.payment_failed,setup_intent.succeededandcharge.refunded; - is in the same mode (test or live) as your keys.
And check its signing secret is saved in Nahnu Links for that mode. No events received yet on the Stripe card means none have arrived.
Stripe’s webhook page shows each attempt and your site’s answer. A 401 or 400 usually means the signing secret doesn’t match; a 403 or a timeout usually means a firewall.
3. Check caching and firewalls#
If your site uses a firewall or cache, allow /wp-json/nl/v1/stripe/webhook and don’t cache /subscribe/. See Use with Nahnu Cache Connector and Bunny Shield.
4. A buyer’s card was declined#
Their invoice shows Payment failed. That’s between the buyer and their bank: ask them to try another card or contact their bank. Renewals are tried again on your retry days, then the subscription goes on hold. See Subscriptions.
Common situations#
| Situation | Likely cause |
|---|---|
| Payment shows in Stripe, but the invoice stays unpaid | The webhook isn’t arriving. Steps 2 and 3. |
| Checkout says the card needs authentication, then nothing happens | The webhook isn’t arriving to confirm it. Steps 2 and 3. |
| Everything worked in test mode, not in live | Live keys or the live webhook are missing. |
| Refunds made in Stripe don’t show on the invoice | charge.refunded isn’t selected on the webhook. |
| Renewals don’t happen at all | WordPress scheduled tasks aren’t running. Set up a real cron job on your host. |


