OpenAI API 429 rate limit how to fix it

You're building something with the OpenAI API and suddenly you're getting slammed with error 429 messages. Your requests fail, your app stalls, and you're wondering what you did wrong. This hits developers hard when they

OpenAI API 429 rate limit how to fix it

You're building something with the OpenAI API and suddenly you're getting slammed with error 429 messages. Your requests fail, your app stalls, and you're wondering what you did wrong. This hits developers hard when they first scale up — or when they're on the free tier testing something new.

What's actually happening

Error 429 means you've hit OpenAI's rate limits. The API returned this because you've sent too many requests in a given timeframe, exceeded your tokens-per-minute quota, or run into your requests-per-minute ceiling.

The actual error looks like this:

```

RateLimitError: Rate limit reached for requests

```

or

```

Error code: 429 - {'error': {'message': 'Rate limit reached for tokens per minute', 'type': 'tokens', 'param': None, 'code': 'rate_limit_exceeded'}}

```

OpenAI sets different limits based on your usage tier. Free tier users get extremely tight limits — often 3 requests per minute for GPT-4 models. Paid users on tier 1 start at 500 RPM (requests per minute) and 10,000 TPM (tokens per minute) for GPT-3.5, but GPT-4 stays much more restricted. As you spend more over time, you automatically move up tiers and get higher limits.

The confusing part: you can hit your token limit even with a single request if you're processing a massive document or conversation history. One 8,000-token request will blow through a 10,000 TPM limit instantly.

How to fix it

1. Check your current tier and limits

Go to platform.openai.com/settings/organization/limits. You'll see your exact RPM and TPM caps for each model. If you're tier 1 and trying to use GPT-4 heavily, you're working with maybe 10,000 TPM — that's roughly 7,500 words total per minute across all requests.

2. Implement exponential backoff

Add retry logic to your code. When you get a 429, wait a few seconds and try again — doubling the wait time with each failure. Here's the pattern:

```python

import time

import openai

for attempt in range(5):

try:

response = openai.ChatCompletion.create(...)

break

except openai.error.RateLimitError:

wait_time = 2 ** attempt

time.sleep(wait_time)

```

Most OpenAI API 429 errors resolve within 5-30 seconds. This code handles temporary spikes automatically.

3. Reduce your token usage per request

Trim your prompts. If you're including full conversation histories, limit to the last 10 exchanges. If you're sending documents, chunk them into smaller pieces. Each request to GPT-4 should ideally stay under 2,000 tokens if you're on a low tier — that gives you headroom for multiple requests.

4. Spread requests over time

If you're processing a batch of 100 items, don't fire all 100 simultaneously. Add a delay between each request — even 0.5 seconds helps. You'll stay under your RPM cap and avoid the 429 wall.

5. Upgrade your tier

This happens automatically as you spend more, but you can also prepay credits to potentially speed up tier increases. Check platform.openai.com/settings/organization/billing to see your current tier. Tier 2 (after spending $50) gives you notably better limits. Tier 4 ($1,000 spent) opens up much higher throughput.

If none of this works and you're still getting blocked constantly, you might be hitting other API errors that look similar. Check our guide on OpenAI API error 429 and other API errors for the full breakdown of 401 authentication failures, 500 server errors, and insufficient_quota messages.

If that doesn't work

Email OpenAI at api-support@openai.com with these details:

  • Your organization ID (from platform.openai.com/settings/organization/general)
  • The exact error message you're receiving
  • Your use case and why you need higher limits
  • Current tier and request volume you're attempting

Response times vary — typically 2-5 business days. They rarely grant manual limit increases for tier 1 users, but if you're on tier 3+ and have a legitimate high-volume use case, they sometimes help. For more on getting through to support, see how to contact OpenAI support.

Some developers create multiple API keys under different projects to split load, but this violates OpenAI's terms. Don't do it — they detect this and will ban all associated accounts.

Questions people actually ask

Q: Why am I getting 429 errors when I've barely used the API today?

A: You're hitting tokens-per-minute limits, not daily limits. One giant request can trigger 429. Check your prompt size and model — GPT-4 has much stricter TPM caps than GPT-3.5.

Q: How long do I have to wait before trying again after a 429?

A: Usually 5-60 seconds. The error sometimes includes a retry-after header telling you exactly how long. If not, start with 5 seconds and double it with each retry.

Q: Will paying for ChatGPT Plus increase my API limits?

A: No. ChatGPT Plus ($20/month) and API billing are completely separate. API limits only increase through API usage spending and tier progression.

What to remember

  • Error 429 means you've exceeded requests-per-minute or tokens-per-minute — not daily quotas
  • Check platform.openai.com/settings/organization/limits for your exact caps
  • Implement exponential backoff retry logic in your code — most 429s resolve in seconds
  • Reduce tokens per request by trimming prompts and splitting large documents
  • Your tier increases automatically as you spend more on the API — tier 2 starts at $50 total spend

---

*openai-support.com is an independent resource, not affiliated with OpenAI Inc.*

Related help