Error library · Stripe test and live mixed up
Stripe “No such price” — a similar object exists in test mode
Checkout is asking Stripe for a price that doesn't exist in the Stripe account it's connected to — usually a price created in test mode being used with the live key, or the other way round. Stripe refuses, so nobody can pay.
Who it affects
Everyone who tries to pay is stopped — 5 sessions so far. This is lost revenue.
Numbers here are from an example app where 5 visitors hit it. How serious: Critical — it stops people using the app, or costs you money.
How to fix it
Give this to the AI that builds your app. It’s the prompt Vigilia writes for this error — shown here for an example app (an orders table, a /checkout page); for your app, Vigilia fills in the real details from what your visitors hit.
For Lovable
Lovable: Bug: Stripe rejects checkout with "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this reque".
Evidence: "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this request." — seen 12 times across ~5 sessions, on /checkout.
What to change:
1. Find where the price (or product) id is configured — usually an environment variable or a constant.
2. Make sure the live site uses ids from the same Stripe mode as its key: live-mode price ids with the live secret key, test-mode ids with the test key. Recreate the price in live mode if it only exists in test mode.
3. Keep the ids in environment variables per environment, so test ids can't reach production again.
4. If Stripe refuses a checkout, show the customer a clear message instead of failing silently.
Acceptance criteria: a real checkout on the live site reaches Stripe's payment page, and no more "No such price" errors.For Bolt
Bolt: Bug: Stripe rejects checkout with "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this reque".
Evidence: "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this request." — seen 12 times across ~5 sessions, on /checkout.
What to change:
1. Find where the price (or product) id is configured — usually an environment variable or a constant.
2. Make sure the live site uses ids from the same Stripe mode as its key: live-mode price ids with the live secret key, test-mode ids with the test key. Recreate the price in live mode if it only exists in test mode.
3. Keep the ids in environment variables per environment, so test ids can't reach production again.
4. If Stripe refuses a checkout, show the customer a clear message instead of failing silently.
Acceptance criteria: a real checkout on the live site reaches Stripe's payment page, and no more "No such price" errors.For Cursor
Cursor: Bug: Stripe rejects checkout with "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this reque".
Evidence: "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this request." — seen 12 times across ~5 sessions, on /checkout.
What to change:
1. Find where the price (or product) id is configured — usually an environment variable or a constant.
2. Make sure the live site uses ids from the same Stripe mode as its key: live-mode price ids with the live secret key, test-mode ids with the test key. Recreate the price in live mode if it only exists in test mode.
3. Keep the ids in environment variables per environment, so test ids can't reach production again.
4. If Stripe refuses a checkout, show the customer a clear message instead of failing silently.
Acceptance criteria: a real checkout on the live site reaches Stripe's payment page, and no more "No such price" errors.For Claude Code
Claude Code: Bug: Stripe rejects checkout with "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this reque".
Evidence: "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this request." — seen 12 times across ~5 sessions, on /checkout.
What to change:
1. Find where the price (or product) id is configured — usually an environment variable or a constant.
2. Make sure the live site uses ids from the same Stripe mode as its key: live-mode price ids with the live secret key, test-mode ids with the test key. Recreate the price in live mode if it only exists in test mode.
3. Keep the ids in environment variables per environment, so test ids can't reach production again.
4. If Stripe refuses a checkout, show the customer a clear message instead of failing silently.
Acceptance criteria: a real checkout on the live site reaches Stripe's payment page, and no more "No such price" errors.For any other tool
Bug: Stripe rejects checkout with "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this reque".
Evidence: "No such price: 'price_1NxExample'; a similar object exists in test mode, but a live mode key was used to make this request." — seen 12 times across ~5 sessions, on /checkout.
What to change:
1. Find where the price (or product) id is configured — usually an environment variable or a constant.
2. Make sure the live site uses ids from the same Stripe mode as its key: live-mode price ids with the live secret key, test-mode ids with the test key. Recreate the price in live mode if it only exists in test mode.
3. Keep the ids in environment variables per environment, so test ids can't reach production again.
4. If Stripe refuses a checkout, show the customer a clear message instead of failing silently.
Acceptance criteria: a real checkout on the live site reaches Stripe's payment page, and no more "No such price" errors.Vigilia catches this automatically
When this happens on your live app, Vigilia recognises it at once — no waiting, no AI credits — tells you who it affects, hands your AI the fix, and confirms it held with real visitors.