> ## Documentation Index
> Fetch the complete documentation index at: https://developer.sandbox.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Rate limits

> Understand API rate limits for test and production environments and how to handle rate limiting.

Sandbox applies rate limits to ensure stable and reliable API performance for all users. When you exceed the rate limit, subsequent requests return a `429 Too Many Requests` status code.

## Rate limits by environment

| **Environment** | **Host url**                     | **Requests per minute** |
| :-------------- | :------------------------------- | :---------------------- |
| Test            | `https://test-api.sandbox.co.in` | 25                      |
| Production      | `https://api.sandbox.co.in`      | 500                     |

## Handling rate limits

When you receive a `429` response:

1. **Pause requests** - Stop sending new requests temporarily
2. **Implement backoff** - Wait before retrying (start with 1 second, then increase)
3. **Reduce frequency** - Spread requests over time

<CodeGroup>
  ```javascript JavaScript theme={null}
  async function makeRequestWithRetry(url, options, maxRetries = 3) {
    for (let i = 0; i < maxRetries; i++) {
      const response = await fetch(url, options);
      
      if (response.status === 429) {
        const waitTime = Math.pow(2, i) * 1000; // Exponential backoff
        await new Promise(resolve => setTimeout(resolve, waitTime));
        continue;
      }
      
      return response;
    }
    throw new Error('Max retries exceeded');
  }
  ```

  ```python Python theme={null}
  import time
  import requests

  def make_request_with_retry(url, headers, max_retries=3):
      for i in range(max_retries):
          response = requests.post(url, headers=headers)
          
          if response.status_code == 429:
              wait_time = (2 ** i)  # Exponential backoff
              time.sleep(wait_time)
              continue
          
          return response
      
      raise Exception('Max retries exceeded')
  ```
</CodeGroup>

<Note>
  Once your request rate falls within the limits, API access automatically resumes.
</Note>

## Custom rate limits

If your app requires higher rate limits than the standard production limit of 500 requests per minute, you can request a custom rate limit increase.

<Tip>
  Contact the [support team](mailto:help@sandbox.co.in?subject=Rate%20Limit%20Increase%20Request) with your use case, expected traffic, and business needs. The team reviews requests and configures suitable limits.
</Tip>

When requesting a rate limit increase, include:

* Current rate limit you're experiencing
* Desired rate limit
* Expected API usage patterns (burst vs sustained)
* Business impact of current limits
