SDK
Pricing

Pricing

CodeSandbox SDK is priced according to the CodeSandbox plans (opens in a new tab). The SDK follows two main pricing components:

  • VM credits: Credits serve as the unit of measurement for VM runtime. One credit equates to a specific amount of resources used per hour, depending on the specs of the VM you are using. VM credits follow a pay-as-you-go approach and are priced at $0.018 per credit. Learn more about credits here.

  • VM concurrency: This defines the maximum number of VMs you can run simultaneously with the SDK. As explored below, each CodeSandbox plan has a different VM concurrency limit.

💡
We use minutes as the smallest unit of measurement for VM credits. E.g.: if a VM runs for 3 minutes and 25 seconds, we bill the equivalent of 4 minutes of VM runtime.

VM credit prices by VM size

Below is a summary of how many VM credits are used per hour of runtime in each of our available VM sizes. Note that, by default, we recommend using the Pico VM size, as it should provide enough resources for most workflows that require basic code interpretation.

VM sizeCredits / hourCost / hourCPURAM
Pico7 credits$0.1262 cores1 GB
Nano10 credits$0.182 cores4 GB
Micro20 credits$0.364 cores8 GB
Small40 credits$0.728 cores16 GB
Medium80 credits$1.4416 cores32 GB
Large160 credits$2.8832 cores64 GB
XLarge320 credits$5.7664 cores128 GB

Concurrent VMs

To pick the most suitable plan for your use case, consider how many concurrent VMs you require and pick the corresponding plan:

  • Free plan: 5 concurrent VMs
  • Pro plan: 20 concurrent VMs
  • Builder plan: 100 concurrent VMs
  • Enterprise plan: custom concurrent VMs

In case you expect a a high volume of VM runtime, our Enterprise plan also provides special discounts (up to 50% off) on VM credits.

Estimating your bill

To estimate your bill, you must consider:

  • The base price of your CodeSandbox plan.
  • The number of included VM credits on that plan.
  • How many VM credits you expect to require.

As an example, let's say you are planning to run 80 concurrent VMs on average, each running 3 hours per day, every day, on the Pico VM size. Here's the breakdown:

  • You will need a Builder plan (which allows up to 100 concurrent VMs).
  • You will use a total of 50,400 VM credits per month (80 VMs x 3 hours/day x 30 days x 7 credits/hour).
  • Your Builder plan includes 1100 free VM credits each month, so you will purchase 49,300 VM credits (50,400 - 1100).

Based on this, your expected bill for that month is:

  • Base price of Builder plan: $170
  • Total price of VM credits: $887.40 (49,300 VM credits x $0.018/credit)
  • Total bill: $1057.40