Open Trivia Database · Rate Limits

Open Trivia Rate Limits

The Open Trivia Database enforces a single, IP-scoped throttling rule on every endpoint it exposes (api.php, api_category.php, api_count.php, api_count_global.php, api_token.php). Each client IP is limited to one request every five seconds. The API does not return rate-limit headers; throttling is signalled through the standard response envelope by setting `response_code` to 5 ("Rate Limit"). There is no paid tier or way to raise the limit — it applies uniformly to all consumers.

Open Trivia Rate Limits is the machine-readable rate-limit profile for Open Trivia Database on the APIs.io network, conforming to the API Commons Rate Limits specification.

It captures 1 rate-limit definition, measuring requests_per_second.

The profile also includes 5 backoff/retry policies defined and response codes documented for throttled and throttledLegacy.

Tagged areas include Rate Limiting, Trivia, Public APIs, and Open Source.

1 Limits Throttle: 429
Rate LimitingTriviaPublic APIsOpen Source

Limits

Per-IP global throttle IP
requests_per_second · second
0.2
One request per IP every five seconds across every Open Trivia Database endpoint. Equivalent to roughly 12 requests per minute and 720 per hour. Exceeding the limit returns the standard envelope with response_code = 5; some intermediaries may surface this as HTTP 429.

Policies

Single-bucket scope
The five-second cooldown is shared across every endpoint. A call to /api_category.php counts the same as a call to /api.php — pace the entire client, not per endpoint.
Use session tokens for batching
To minimise the number of /api.php calls a client needs, request the largest reasonable `amount` (up to 50) and pair it with a session token from /api_token.php. The token guarantees no duplicates across calls until reset or six-hour expiry, reducing wasted requests.
Back off on response_code 5
When `response_code` is 5, pause for at least five seconds before retrying. Exponential backoff is not required but is recommended for shared-IP environments (CI, datacenter NAT).
No way to raise the limit
The throttle applies to all consumers regardless of identity. There is no API key, no paid tier, and no contact path to lift it. Hosting a local mirror via the OpenTDB download script is the recommended escape hatch for heavy workloads.
Honour response_code over HTTP status
Trust the JSON `response_code` field as the primary signal for both success and throttling. The HTTP status is almost always 200, even when throttled — making body parsing mandatory.

Sources