Skip to main content
ScrapeBadger uses tier-based rate limiting to ensure fair usage and reliable performance for all users.

How Rate Limiting Works

Tier-Based Limits

Your rate limit is determined by your account tier. All API keys inherit the same limit from your account.

Sliding Window

We use a sliding window algorithm for accurate rate limiting. Limits are calculated per minute with smooth request distribution.

Real-Time Headers

Every response includes rate limit headers so you can monitor usage and implement smart retry logic.

Rate Limits by Tier

TierRequests/MinuteDescription
Free60Default tier for new accounts
Basic300For small-scale applications
Pro1,000For production applications
Enterprise5,000For high-volume applications

Rate Limit Headers

Every API response includes these headers to help you track your rate limit usage:
HeaderDescriptionExample
X-RateLimit-LimitMaximum requests allowed per minute for your tier300
X-RateLimit-RemainingRequests remaining in the current window287
X-RateLimit-ResetUnix timestamp when the rate limit window resets1703123456
Retry-AfterSeconds until you can retry (only on 429 responses)45

Rate Limit Exceeded Response

When you exceed your rate limit, the API returns a 429 Too Many Requests response:
{
  "detail": "Rate limit exceeded",
  "limit": 300,
  "remaining": 0,
  "reset_at": 1703123456,
  "tier": "basic"
}

Handling Rate Limits

# Check rate limit headers in response
curl -i -H "x-api-key: sb_live_xxx" \
  https://scrapebadger.com/v1/twitter/tweets/123

# Response headers:
# X-RateLimit-Limit: 300
# X-RateLimit-Remaining: 299
# X-RateLimit-Reset: 1703123456

Best Practices

Monitor rate limit headers

Check X-RateLimit-Remaining on each response to proactively slow down before hitting limits.

Implement exponential backoff

When rate limited, wait the Retry-After time and consider increasing wait time on repeated limits.

Use request queuing

Queue requests and process them at a controlled rate to stay within your limits.

Cache responses

Cache API responses where appropriate to reduce the number of requests you need to make.
Avoid Rate Limit AbuseRepeatedly hitting rate limits or attempting to bypass them may result in temporary or permanent restrictions on your account.
  • Don’t create multiple accounts to circumvent limits
  • Don’t use rotating API keys to bypass rate limiting
  • Contact support if you need higher limits

FAQ

Rate limits are applied per API key using a sliding window algorithm. Each API key has its own separate rate limit counter based on your account tier.
The API returns a 429 Too Many Requests response with details about when you can retry. Use the Retry-After header to know when to try again.
Yes, all requests (successful or not) count against your rate limit. However, rate limits are generous and designed to accommodate normal usage patterns.
All API keys inherit the rate limit from your account tier. To get higher rate limits, upgrade your account tier.
Every API response includes rate limit headers (X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset) so you can track your usage in real-time.

Need higher rate limits? Contact us at sales@scrapebadger.com.