LowCodeStacks™
Sign in

Azure OpenAI 429 Too Many Requests: why you're throttled below quota

An Azure OpenAI 429 Too Many Requests rarely means you're out of quota. The rate limit counts reserved tokens in short windows. Read the headers, then fix the cause.

AI & agentsFix a problem9 min read

Checked against Microsoft Learn 5 sources · Updated By · drafted with AI help, checked by a personHow we write guides

A 429 "Too Many Requests" from Azure OpenAI in Microsoft Foundry is the most misread error on the platform. The usage charts say you're well under quota, yet calls fail, so people request more quota and nothing changes. The rate limit and the usage metrics measure different things, and there are four different reasons for a 429 that each need a different fix. This guide shows how to tell them apart and what to do for each.

When Azure OpenAI returns a 429, first read the message and the x-ratelimit headers. Each of four signals points to its own cause and fix. One: the message says rate limit is exceeded or requests have been limited; you went over the deployment's TPM or RPM; give the deployment more TPM, rebalance from a quiet one, or request more quota. Two: the message says high demand or that the service is temporarily unable to process your request; shared capacity is constrained, usually briefly; retry after retry-after-ms and, if it persists, consider provisioned throughput. Three: the x-ratelimit-limit-tokens header is lower than the TPM you configured; your effective limit has been reduced temporarily to protect the shared pool; retry with backoff, it normally clears within hours, and spread or ramp traffic. Four: you are rate limited while token metrics look low; your requests reserve more tokens than they use through max_tokens; lower max_tokens to the size of the answers you expect.
Four kinds of 429, each with its own signal, cause and fix.

Read the 429 error before you act

Every response carries rate-limit headers. On a 429, read them before you change anything:

HeaderMeaning
x-ratelimit-limit-requests, x-ratelimit-limit-tokensThe deployment's limits per minute, as enforced right now
x-ratelimit-remaining-requests, x-ratelimit-remaining-tokensWhat's left in the current minute
x-ratelimit-reset-requests, x-ratelimit-reset-tokensHow long until each counter resets
retry-after-msOn a 429: how long to wait before trying again

Then match the message to its cause:

What the message saysThe causeWhat fixes it
"Requests to … have been limited" or "Rate limit is exceeded"You went over the deployment's TPM or RPMGive the deployment more TPM, rebalance from a quiet one, or request more quota
"The service is temporarily unable to process your request" or "System is experiencing high demand"Shared capacity is constrained, usually brieflyRetry after retry-after-ms; if it persists, consider provisioned throughput
429s while x-ratelimit-limit-tokens is lower than the TPM you configuredA temporary reduction of your effective limit to protect the shared poolRetry with backoff; it normally clears within hours; spread or ramp traffic
Rate limited while token metrics look lowYour requests reserve more tokens than they use, through max_tokensLower max_tokens to the size of the answers you expect

Microsoft says it plainly: many customers treat capacity-related 429s as quota problems and request increases that can't help.

"The system is currently experiencing high demand and cannot process your request"

This is the 429 people most often paste into a search box. Microsoft's quota page quotes only its key words, "System is experiencing high demand"; as people report it from their apps, the full message reads:

text
The system is currently experiencing high demand and cannot process your request. Your request exceeds the maximum usage size allowed during peak load. For improved capacity reliability, consider switching to provisioned throughput.

In reports we've seen, some tools put other words in front of it, such as Rate limit exceeded: or stream disconnected before completion:. Read past them to the message itself.

What it means. Microsoft's guide to 429s files messages that say the system is experiencing high demand under system capacity throttling. The shared capacity behind standard (pay-as-you-go) deployments is under pressure, and the condition is often brief. It isn't your quota running out, so asking for more quota won't fix it. Microsoft doesn't explain the words "maximum usage size" anywhere we could find, so don't read a particular limit into them.

What to do, following Microsoft's guidance:

  1. Retry after the retry-after-ms delay, with backoff and a cap on attempts (see Retry properly). Occasional 429s like this are expected on standard deployments.
  2. Smooth your traffic. Avoid sharp bursts, ramp new workloads up gradually, and spread requests across deployments or regions if one can't carry the load.
  3. If it keeps happening in production, do what the message suggests and look at provisioned throughput: dedicated capacity with guaranteed rate limits, which doesn't share the standard pool.

Why you are throttled below quota

The usage metrics in Azure Monitor show billed tokens from successful requests. The rate limit is applied to requests as they arrive, with an estimate, and that estimate is what fills the bucket:

  • The token estimate includes max_tokens (and best_of), not just the prompt. A request that expects a 200-token answer with max_tokens set to 4,000 reserves 4,000 against your limit, even though you're billed for the real output. The estimate is also based partly on character count, so it's approximate and can trip earlier than an exact count would.
  • Requests per minute are checked in short windows, typically 1 or 10 seconds. A 600 RPM deployment allows about 10 requests a second; a burst of 30 in one second is throttled even if the minute's total is fine.
  • Rejected and failed requests still count. A request refused with a 400, for being too long or by the content filter, can count against the limit without appearing in billed usage. Retrying without backing off makes it worse.
  • Shared capacity can be reduced temporarily. Standard, pay-per-token deployments share a pool. When demand nears its limits, the service lowers a deployment's effective rate for a while. You can see it: the header's limit drops below your configured TPM.
  • Quota must sit on the deployment that gets the traffic. Approved subscription quota does nothing until it's allocated to that deployment, and enforcement across a distributed service isn't perfectly precise either.

Tip

Watch x-ratelimit-remaining-tokens and x-ratelimit-remaining-requests in your own code and slow down before the 429 arrives, rather than after.

Retry properly

Honour retry-after-ms when it's present; otherwise back off exponentially with random jitter, and cap the attempts. The openai Python package already does this for 429s, with two retries by default; raise it on the client rather than writing your own loop:

python
from openai import AzureOpenAI

client = AzureOpenAI(
    azure_endpoint="https://<your-resource>.openai.azure.com/",
    api_key="<your-api-key>",
    api_version="2024-10-21",
    max_retries=5,  # exponential backoff with jitter, honours retry-after
)

If you use a retry library such as tenacity or Polly instead, set the SDK's max_retries to 0 first. Otherwise every attempt of yours can trigger up to two SDK retries of its own, and the extra requests count against the same limit.

Then shrink what each request reserves:

  • Set max_tokens to the smallest value your scenario needs. This is the single most common fix. (Reasoning models take max_completion_tokens instead, and it must leave room for their reasoning tokens; Microsoft's rate-limit pages describe the estimate in terms of max_tokens.)
  • Leave best_of at 1 unless you really need several completions; each increment multiplies the token count.
  • Shorten prompts where you can.
  • Spread traffic. Ramp new workloads up gradually; avoid sharp spikes; split across deployments or regions when one deployment can't carry the load; queue work that doesn't need an immediate answer.

Check and rebalance quota

Quota is tokens per minute per subscription, region, model and deployment type, and each deployment takes a slice of it.

  1. Open the quota page in the Foundry portal, in its Manage section. Its tokens-per-minute view shows each deployment's allocation and usage, and from the list of deployments sharing a quota you can move TPM between them. Changes take up to 15 minutes.
  2. To see it you need the Cognitive Services Usages Reader role at the subscription scope, not on the resource group or the resource.
  3. For a script or an alert, the Usages API returns every quota line in a region with currentValue and limit; the Model Capacities API says where a model can still be deployed and how much capacity is free.
  4. When the whole subscription is short, submit Microsoft's quota increase form. Requests are handled in order, and priority goes to subscriptions that actively use what they have.

When to escalate or move to provisioned throughput

SituationDo this
Occasional 429s that clear with retry-after-msRetry. This is normal on standard deployments and not a defect
429s in development or testingOften fine; a small deployment there is a cost guardrail
Sustained 429s in production while under the quota you were approved forCheck the allocation on the deployment first, then open a support request
A quota increase that doesn't show in the effective limitsVerify the deployment-level allocation, then escalate
Frequent 429s on a latency-sensitive production workloadMove to provisioned throughput: reserved capacity with guaranteed limits, and spillover to a standard deployment for bursts beyond it

Provisioned deployments measure utilisation differently and don't share the pool, so they're the answer for work that needs the same throughput at the same latency every minute. For everything else, the fixes above are usually enough.

Sources

Add LowCodeStacks as a preferred source on Google

Did this fix it?

Get the weekly email

New guides and updates from LowCodeStacks, every Tuesday. One email a week, no more.

From LowCodeStacks, Regina, SK, contact@lowcodestacks.com. You can unsubscribe any time, from the link in every email or in your privacy settings. See the Privacy notice.

Comments

No comments yet. Share what worked for you.

Sign in to comment. Comments show under a display name you choose, never your email.