Sandbox URLs
Create your sandbox account and API keys at sandbox.whop.com.
Software development kit configuration
To use the sandbox environment with the Whop SDK, pass theSandbox environment. An environment names every host the SDK talks to, so every request moves to the sandbox at once.
The
Sandbox environment arrived in SDK 2.0. On 1.x, point the client at https://sandbox-api.whop.com/api/v1 instead: baseUrl in TypeScript, base_url in Python and Ruby, option.WithBaseURL in Go. TypeScript, Ruby and Go keep that override in 2.0, but it sends every request to one host. Operations that must reach a different host are then refused, so use environment. The 2.0 Python client has no base_url parameter. The Rust SDK is still 1.x and keeps base_url.Elements in the sandbox
To point Whop Elements at the sandbox, setenvironment when you create the SDK instance. This option is the only way to change where the elements send what a buyer types.
The Elements property for selecting a variant remains named plan for compatibility.
Application programming interface keys and webhooks
API keys and webhooks work the same in sandbox as they do in production:- Create API keys at sandbox.whop.com/dashboard/developer
- Configure webhooks to receive events from sandbox
- Use the same authentication headers (
Authorization: Bearer YOUR_API_KEY)
Test cards
Use the following test card numbers to simulate payments in sandbox:
In production, a declined payment carries a code from the card issuer. Payment decline codes explained lists what each one means.
For all test cards:
- Use any future expiration date (e.g., 12/34)
- Use any 3-digit card verification code (e.g., 123)
- Use any billing address
4000 0000 0000 0341 to test recovery flows where you save a card
successfully, but a future charge for that saved card fails.
Payment methods in the sandbox
To test card payments, use the test cards above. These methods also complete in the sandbox through each provider’s own test flow: PayPal, Bancontact, iDEAL, Cash App Pay, Pix, and Boleto. These methods aren’t supported in the sandbox yet:- Apple Pay and Google Pay
- Bank accounts (ACH)
- SEPA Direct Debit
- EU bank transfers and wire transfers
- Alipay, WeChat Pay, and MobilePay
Known limitations
- Payouts
- Crypto deposits and on-chain transfers
- Discord direct messages and role sync
- Up-to-date search results
- Some scheduled and background jobs that run in production, such as fraud reviews and digest emails

