Recover failed payments
Failed-payment emails, recovery rate, and why customers cancel by channel and MRR.
The Recover page tracks every failed payment until it is paid or lost, can email the customer a link to update their card, and shows why customers cancel, with the channel that first brought them and the monthly revenue that left.
Add the events
Recover uses the same webhook as revenue. Add these events to it in your provider's dashboard:
| Stripe | invoice.payment_failed (opens a failed payment), invoice.paid (closes it as recovered), customer.subscription.updated and customer.subscription.deleted (cancellation reasons, and marks a failed payment lost when the subscription ends). invoice.marked_uncollectible and invoice.voided are optional and mark it lost. |
| Lemon Squeezy | subscription_payment_failed, subscription_payment_recovered, subscription_payment_success and subscription_updated (it carries the link to update the card) |
| Polar | subscription.past_due (opens a failed payment when a renewal charge fails), subscription.updated (closes it as recovered when the subscription is active again), order.paid (records the amount the retry brought in) and subscription.revoked (marks it lost when retries run out). Polar sends no card link, so set the billing page link for reminder emails. Cancellation reasons work through the exit survey. |
Until a failed payment arrives, the page reminds you to add the event.
The numbers
| Recovered | Failed payments that were paid later, by the date they were paid. |
| Recovery rate | Of the payments that failed in the period, the share that has been paid since. |
| Open now | Failed payments still waiting on a retry or a new card. |
| Lost | The provider gave up, or the subscription ended unpaid. |
Reminder emails
Off by default. Turn them on in the Failed-payment emails card and add a reply-to address. Pathrail then emails the customer right away, on day 3 and on day 7 (change the days, subjects and text as you like, up to five emails). Each email comes from your site's name and has an Update your card button:
- Stripe: the invoice's own payment page, where the customer pays with a new card.
- Lemon Squeezy: the subscription's update-payment-method page.
- Polar, or any provider without a link: the billing page link you set, such as your Polar customer portal.
The sequence stops as soon as the invoice is paid, the payment is lost, or the customer clicks the link at the bottom to stop the emails. Only payments that fail after you turn reminders on get them. In subjects and text, {product} is your site name, {amount} the payment and {link} the card link.
To send them, Pathrail keeps the customer's email address encrypted on the failed payment. Reports only ever show it masked.
Why customers cancel
Reasons come from two places, and each customer counts once, with their own survey answer first:
- Stripe's cancel page, when the customer portal asks for a reason. Pathrail reads the reason and comment from the subscription.
- The exit survey: a hosted page that asks for one reason (too expensive, missing a feature, switched to another tool, not using it enough, technical issues, or other with a comment).
Send customers to the survey from your cancel flow. Pass their email so the answer joins their subscription and first visit:
https://pathrail.io/cancel/<site key>?email=customer@example.com
Or open it as a modal over your own page, where the Pathrail script is installed:
pathrail("cancel_survey", { email: user.email, onClose: () => finishCancel() });If the script is served from your own domain through a proxy, add data-home="https://pathrail.io" to the script tag so the modal knows where the survey lives. The site key is the pr_... value in your snippet; the Recover page shows the full link.