Rate limits
The BSR enforces rate limits to prevent abuse and ensure availability for all users.
Where rate limits apply
Public BSR (buf.build)
All users accessing the public BSR are subject to rate limits. Rate limits apply to all traffic against the public BSR (buf.build), including Community, Teams, Pro, and Enterprise plan users.
Pro and Enterprise instances
Pro and Enterprise customers have access to dedicated instances without rate limits. We encourage these users to use their dedicated instances for production workloads.
Limits
Note: Burst capacity allows you to make multiple requests quickly, then wait for your rate limit to replenish.
General API requests
All Connect services have a default rate limit:
- Limit: 30 requests per second
- Burst: 60 requests
Code generation
Unauthenticated requests
- Limit: 10 requests per hour
- Burst: 10 requests
Authenticated requests
- Limit: 960 requests per hour
- Burst: 120 requests
Buf CLI usage
Each buf generate
command that uses remote plugins counts as one request, with a maximum of 20 plugins per request.
Examples:
buf.gen.yaml
with 15 remote plugins = 1 requestbuf.gen.yaml
with 22 remote plugins = Request rejected
FileDescriptorSetService
- Limit: 1 request per second
- Burst: 2 requests
Monitoring your rate limit
Check these response headers to monitor your current rate limit status:
Header | Description |
---|---|
X-RateLimit-Limit | Total requests allowed in the current time window |
X-RateLimit-Remaining | Remaining requests in the current time window |
X-RateLimit-Reset | Seconds until the rate limit window resets |
Retry-After | When rate limited, seconds to wait before retrying |
Exceeding the rate limit
Requests that exceed a rate limit return HTTP status code 429 with X-RateLimit-Remaining
set to 0
. Wait for the number of seconds specified in the Retry-After
header before retrying.
Increasing your rate limit
- Authenticate your requests - Increases rate limits for certain services.
- Upgrade to Pro or Enterprise - Access dedicated instances without rate limits.
- Contact us if you believe you're hitting limits inappropriately.
For questions about rate limits or to discuss your specific needs, contact us.