← All errors · Stripe
No such customer: 'cus_...'
Exact error
No such customer: 'cus_XXXXXXXX'
What it means
The ID doesn't exist in the Stripe account and mode you are calling. The same pattern applies to "No such price", "No such product", etc.
Likely causes
- The object was created in test mode and you are using a live key (or the reverse).
- The object belongs to a different Stripe account (or a connected account).
- The ID stored in your database is stale or was deleted.
How to fix it
Check which mode the key is in: sk_test_ vs sk_live_. Test and live data are fully separate.
Look up the ID in the Dashboard with the matching mode toggle.
For Connect, pass the account header:
await stripe.customers.retrieve('cus_123', { stripeAccount: 'acct_123' });
Related errors
Get new fixes weekly
No spam. Unsubscribe anytime. Privacy