> ## Documentation Index
> Fetch the complete documentation index at: https://docs.novita.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Quota Limits

Novita Sandbox applies quota limits based on your account tier. Quotas define the resources and capabilities available to each tier.

If you need higher limits, please [contact our support team](https://meet.brevo.com/novita-ai/contact-sales).

## Account Tiers

| Account Tier | Description                                                                      |
| ------------ | -------------------------------------------------------------------------------- |
| Free         | The default tier for new users.                                                  |
| Paid         | Available after adding account balance or enabling a credit line.                |
| Enterprise   | Designed for enterprise customers that need custom limits and dedicated support. |

## Default Quotas

| Limit                    | Free      | Paid      | Enterprise                     |
| ------------------------ | --------- | --------- | ------------------------------ |
| Concurrent sandboxes     | 5         | 100       | 500 by default, adjustable     |
| Maximum session duration | 1 hour    | 3 hours   | 4 hours by default, adjustable |
| Maximum vCPU             | 2 vCPU    | 8 vCPU    | 8 vCPU by default, adjustable  |
| Maximum memory           | 4 GiB     | 8 GiB     | 8 GiB by default, adjustable   |
| Local disk space         | 20 GB     | 20 GB     | 20 GB by default, adjustable   |
| Memory increment         | 512 MiB   | 512 MiB   | 512 MiB                        |
| Memory per vCPU          | 0.5-4 GiB | 0.5-4 GiB | 0.5-4 GiB                      |

## Configuration Rules

When configuring CPU and memory, your configuration must meet the following requirements:

* vCPU must not exceed the maximum vCPU limit for your account tier.
* Memory must not exceed the maximum memory limit for your account tier.
* vCPU must be configured as an integer value, such as 1, 2, 4, or 8 vCPU.
* Memory must be configured in 512 MiB increments.
* Memory must be within the allowed range of 0.5-4 GiB per vCPU.

For example:

* 1 vCPU supports 512 MiB to 4 GiB of memory.
* 2 vCPU supports 1 GiB to 8 GiB of memory.
* 4 vCPU can support up to 16 GiB of memory based on the memory-per-vCPU range, but the actual available memory is still limited by the maximum memory quota of your account tier.

The final available configuration is determined by both your account tier limits and the allowed memory-per-vCPU range.

## Check Current Quota Usage

Use the quota API to check the quota limits available to your account and the resources currently in use. This is useful before launching a large batch of sandboxes or when troubleshooting quota-related launch failures.

### Check quota usage using the SDKs

<CodeGroup>
  ```js JavaScript & TypeScript icon="js" theme={"system"}
  import { Sandbox } from 'novita-sandbox'

  const quota = await Sandbox.getQuota()

  console.log('Quota limit:', quota.limit)
  console.log('Current usage:', quota.usage)

  // Example shape:
  // {
  //   limit: {
  //     concurrentInstances: 100,
  //     concurrentVcpu: 200,
  //     concurrentRamMb: 409600,
  //     maxLengthHours: 4,
  //     diskMb: 20480,
  //     maxVcpu: 8,
  //     maxRamMb: 8192
  //   },
  //   usage: {
  //     concurrentInstances: 12,
  //     concurrentVcpu: 24,
  //     concurrentRamMb: 49152
  //   }
  // }
  ```

  ```python Python icon="python" theme={"system"}
  from novita_sandbox.core import Sandbox

  quota = Sandbox.get_quota()

  print('Quota limit:', quota.limit)
  print('Current usage:', quota.usage)

  # Example shape:
  # {
  #   "limit": {
  #     "concurrentInstances": 100,
  #     "concurrentVcpu": 200,
  #     "concurrentRamMb": 409600,
  #     "maxLengthHours": 4,
  #     "diskMb": 20480,
  #     "maxVcpu": 8,
  #     "maxRamMb": 8192,
  #   },
  #   "usage": {
  #     "concurrentInstances": 12,
  #     "concurrentVcpu": 24,
  #     "concurrentRamMb": 49152,
  #   },
  # }
  ```
</CodeGroup>

### Quota response fields

The quota response includes `limit` and `usage` objects.

| Field                       | Description                                                                      |
| --------------------------- | -------------------------------------------------------------------------------- |
| `limit.concurrentInstances` | Maximum number of sandboxes that can run concurrently.                           |
| `limit.concurrentVcpu`      | Maximum total vCPU cores that can be used concurrently.                          |
| `limit.concurrentRamMb`     | Maximum total RAM that can be used concurrently, in MiB.                         |
| `limit.maxLengthHours`      | Maximum lifetime for a single sandbox, in hours.                                 |
| `limit.diskMb`              | Available runtime storage for a single sandbox, in MB.                           |
| `limit.maxVcpu`             | Maximum vCPU cores for a single sandbox. Applies after the template is built.    |
| `limit.maxRamMb`            | Maximum memory for a single sandbox, in MB. Applies after the template is built. |
| `usage.concurrentInstances` | Current number of running sandboxes.                                             |
| `usage.concurrentVcpu`      | Current total vCPU cores in use.                                                 |
| `usage.concurrentRamMb`     | Current total RAM in use, in MB.                                                 |

Quota usage is intended for capacity planning and troubleshooting. Usage data may have a short delay, depending on the backend resource reporting path.

## Notes

* If your resource configuration exceeds the quota for your account tier, the request will fail.
* If a region has no available capacity,  If a region has no available capacity, sandbox creation may fail even if your account-level quota is not exhausted.
* Choose CPU and memory based on your workload requirements to avoid out-of-memory errors or unnecessary resource usage.
* Enterprise quotas can be customized based on your requirements. To request a quota increase, please [contact our support team](https://meet.brevo.com/novita-ai/contact-sales).
