Skip to main content
Whop provides a sandbox environment for testing your integration without affecting production data or making real payments.

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 the Sandbox 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, set environment 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.
The sandbox environment isn’t available for Whop Elements yet. The samples below run as written once it is.

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: 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
Use 4000 0000 0000 0341 to test recovery flows where you save a card successfully, but a future charge for that saved card fails.

Known limitations

The sandbox environment has some limitations compared to production:
The following features aren’t available or may not work as expected in sandbox:
  • Payouts - Payout functionality isn’t available yet
  • Apps & Messaging - Don’t use apps or messaging features in sandbox
  • Alternative payment methods - The sandbox supports only card payments (no Apple Pay, Google Pay, etc.)