Configure
Learn how to set up Stripe payments for local development.
Set Up Stripe
Create an account
Sign up for sign in on on Stripe.
Activate test mode
Activate test mode at the top right corner of the dashboard.
Get the Stripe keys
Go to Settings → Developers and click Manage API keys.
Copy the Publishable key and paste it beside STRIPE_PUBLISHABLE_KEY in the .env file.
Copy the Secret key and paste it beside STRIPE_SECRET_KEY in the .env file.
STRIPE_PUBLISHABLE_KEY=your-stripe-publishable-key
STRIPE_SECRET_KEY=your-stripe-secret-keyInstall the Stripe CLI
Follow the instructions on the Stripe CLI page to install it.
The Stripe CLI is needed to receive webhook events during local development.
Run the webhook listener:
pnpm stripeCopy the webhook signing secret from the terminal output and paste it beside STRIPE_WEBHOOK_SECRET in the .env file.
STRIPE_WEBHOOK_SECRET=your-stripe-webhook-secretKeep the webhook listener running while developing locally.
Environment Variables
STRIPE_PUBLISHABLE_KEY=pk_test_...
STRIPE_SECRET_KEY=sk_test_...
STRIPE_WEBHOOK_SECRET=whsec_...Next Steps
- Configure Subscription Plans to push products and prices to Stripe