AI & information

AI API error 429: when to retry and when to check billing

Read the error details before retrying. Separate temporary throughput limits from quota or billing problems.

OpenAI added project-level service-tier controls on October 21, 2026. A disallowed service_tier now has a documented 400 error; it is not a temporary 429. This makes reading the actual error code especially useful when a previously working task stops. Keep project policy, throughput and billing checks separate.

A 429 response does not always mean “try again in a minute.” In the OpenAI API, a temporary rate limit and a spending or quota problem require different responses. Read the error body and your project’s limits before starting another request.

Make retries finite

For a temporary rate limit, honor a valid Retry-After value as a minimum wait. Add a small random delay; otherwise, use exponential backoff with jitter. Limit both attempts and total waiting time. Include the SDK’s automatic retries in that budget.

For example, give a background task three attempts within a two-minute window. If the server asks for a longer wait, postpone the task instead of ignoring that instruction. These are example application settings, not provider limits.

Check the outcome

Log the error type and request ID without logging secrets. A quota or billing error needs account action; repeated retries cannot replenish a balance. After a successful retry, confirm that the intended item was processed only once.

Inspect error.code, not only the broader insufficient_quota type. For example, credit_balance_exhausted points to prepaid credits, while project_spend_limit_exceeded points to the project’s enforced spending limit. Neither is fixed by retrying. Ask the account administrator to review the matching control before resuming; do not raise budgets automatically.

Sources & further reading

  1. OpenAI — API changelog, 21 October 2026
  2. OpenAI — Error codes and service-tier restrictions
  3. OpenAI — Rate limits

Sources support the technical explanations. Examples and suggested checks are editorial guidance.