Skip to content

Rate Limits

AstroAPI enforces rate limits to ensure fair usage and platform stability.

Default Limits

Rate limits are determined by your subscription plan:

SubscriptionRequests/minuteRequests/month
Basic60150,000
Gold120300,000
Premium300750,000
Deluxe6001,000,000

Your specific rate limits depend on your active subscription. Check the dashboard for your current limits.

Rate Limit Headers

All responses include rate limit information:

http
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 55
X-RateLimit-Reset: 1699999999

Handling Rate Limits

When you exceed the rate limit, the API returns a 429 Too Many Requests response:

json
{
  "errors": [{
    "status": "429",
    "title": "Too Many Requests",
    "detail": "Rate limit exceeded. Please retry after 60 seconds."
  }]
}

Retry Strategy

Implement exponential backoff when receiving 429 responses:

typescript
async function fetchWithRetry(url: string, options: RequestInit, maxRetries = 3) {
  for (let i = 0; i < maxRetries; i++) {
    const response = await fetch(url, options);

    if (response.status !== 429) {
      return response;
    }

    const retryAfter = response.headers.get('Retry-After') || '60';
    await new Promise(resolve =>
      setTimeout(resolve, parseInt(retryAfter) * 1000)
    );
  }

  throw new Error('Max retries exceeded');
}

Endpoint-Specific Limits

Some endpoints have additional limits:

EndpointAdditional Limit
/api/chart/*100 renders/hour
/api/calc/batch10 batch requests/minute

Increasing Limits

Contact support to discuss custom rate limits for your application.

AstroAPI Documentation