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

# Rate Limiting & Quotas

> API rate limits and usage quotas

## Rate Limit Overview

API requests are rate limited to ensure fair usage and system stability. Limits are enforced at two levels: **per IP address** and **per user account**.

## Current Limits

| Dimension        | Limit                 |
| ---------------- | --------------------- |
| Per IP address   | 60 requests / minute  |
| Per user account | 600 requests / minute |

<Note>
  When either limit is exceeded, the API returns HTTP status `429 Too Many Requests`. Limits may vary based on your plan — contact support for higher limits.
</Note>

## Rate Limit Exceeded Response

When a rate limit is exceeded, the API responds with:

```json theme={null}
{
  "success": false,
  "message": "Rate limit exceeded. Please retry later.",
  "error_code": "RATE_LIMIT_EXCEEDED"
}
```

## Handling Rate Limits

### Implement Exponential Backoff

```javascript theme={null}
async function apiRequestWithBackoff(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;
      console.log(`Rate limited. Retrying in ${waitTime}ms...`);
      await sleep(waitTime);
      continue;
    }

    return response;
  }

  throw new Error('Max retries exceeded due to rate limiting');
}
```

### Best Practices

* Implement exponential backoff with jitter for retries
* Cache responses when possible to reduce redundant requests
* Batch operations where supported (e.g. batch document removal)
* Implement client-side request queuing to smooth out traffic spikes
* Monitor request volume and log `429` responses for observability

## Storage Quotas

| Resource             | Limit                   |
| -------------------- | ----------------------- |
| Total storage        | 100 GB (varies by plan) |
| Max file size        | 500 MB                  |
| Projects             | Unlimited               |
| Memories per project | Unlimited               |
| API keys per project | 10                      |

## Requesting Higher Limits

To request higher rate limits, contact support with:

* Current usage patterns and peak request volume
* Expected future usage
* Use case description

## Next Steps

<CardGroup cols={2}>
  <Card title="API Overview" icon="book" href="/features/memorylake/api-reference/overview">
    Return to API overview
  </Card>

  <Card title="Error Handling" icon="triangle-exclamation" href="/features/memorylake/api-reference/errors">
    Handle rate limit errors
  </Card>
</CardGroup>
