New to VisionScaper?
Start here
Help Center › Get your API keys › Replace or rotate a Stripe key
Replace or rotate a Stripe key
Safely swap the Stripe secret key or webhook secret in VisionScaper without dropping payments.
Replace a Stripe key if it leaked, if someone who knew it left, or if you lost it. This article gives the order that keeps payments working.
Before you start
You need access to the Stripe Dashboard and to Settings → VisionScaper in WordPress.
Steps: rotate the secret key
- In Stripe, open the API keys page.
- Click the overflow menu (three dots) next to the key and choose Rotate key.
- Pick an expiry in the Expiration list. Stripe’s page says both old and new keys work for up to 7 days when you use its grace period. Choosing Now deletes the old key at once.
- Click Rotate API key.
- Click the new key value to copy it, then save it. Stripe will not show it again.
- In WordPress, paste it into Stripe secret key and save.
- Wait until the old key shows no requests, then expire it.
Steps: roll the webhook secret
- In the Webhooks tab, click the destination.
- Open its overflow menu and choose Roll secret.
- You can expire the current secret now or delay up to 24 hours. Delay it while you update VisionScaper.
- Copy the new
whsec_value into Stripe webhook signing secret and save.
Steps: if a key leaked
- Rotate it with Now as the expiry.
- Check the key’s request log (overflow menu, View request logs).
- Contact Stripe support if you see requests you do not recognize.
Tips
- Add a note to each key that says where it lives.
- Stripe offers access policies that limit a key to certain IP addresses. Whether your host has a fixed IP is up to your host.
If something goes wrong
- Payments stop right after rotating. You chose Now and VisionScaper still has the old key. Paste the new one.
- Stripe says the key has limited access. Stripe can limit a key not used for payouts or transfers in 180 days. Use Restore access in the overflow menu.
Sources
- Stripe, API keys (rotate, expire, restore): https://docs.stripe.com/keys (read 2026-10-15)
- Stripe, webhooks (roll secret): https://docs.stripe.com/webhooks