Try Bifrost Enterprise free for 14 days. Request access

Claude API 529 Overloaded Error: Causes and How to Fix It

The Claude overloaded error (HTTP 529) means Anthropic's API is temporarily at capacity, not that your account hit a limit. This guide covers where it appears in the API, streams, and Claude Code, with code for retries, model fallback, and Bedrock or Google Cloud failover.

Claude API 529 Overloaded Error: Causes and How to Fix It

TL;DR

  • A Claude overloaded error is an HTTP 529 with the type overloaded_error: the Claude API is temporarily at capacity, and the error does not count against your usage quota.
  • A 529 differs from a 429, which means your organization hit a rate limit or spend cap, and from a 500 or 504, which signal an internal error or a processing timeout.
  • The Anthropic SDKs retry a 529 twice by default, but not an overloaded_error that arrives inside a stream that has already started.
  • The fix order is bounded retries with jitter, then a fallback Claude model, then the same model on Amazon Bedrock or Google Cloud.
  • Bifrost retries 529s with backoff and jitter, then falls back across Anthropic, Bedrock, and Vertex behind one Anthropic SDK endpoint.

The Claude overloaded error is an HTTP 529 response with the type overloaded_error, which the Claude API returns when it is temporarily at capacity. It appears as a 529 status in direct API calls, as API Error: Repeated 529 Overloaded errors in Claude Code, and as an error event inside streams that have already started. This guide explains what the error means, how it differs from 429 and 5xx errors, and how to fix it with retries, model fallback, and cross-cloud failover through Bifrost, the open-source AI gateway built by Maxim AI.

What the Claude Overloaded Error Means

A Claude overloaded error means the Claude API could not take a valid request because it was temporarily at capacity. Anthropic's API errors reference lists it as status 529, type overloaded_error, and notes that it can occur during high traffic across all users. The same request usually succeeds seconds later.

The body follows Anthropic's standard error shape (message text may vary):

{
  "type": "error",
  "error": { "type": "overloaded_error", "message": "Overloaded" },
  "request_id": "req_011CSHoEeqs5C35K2UUqR7Fy"
}

Three facts shape the fixes:

  • It is not about your account. Claude Code's error reference states that a 529 does not count against your quota, so a higher rate limit does not prevent it.
  • Capacity is tracked per model. Anthropic's Claude Code docs note this, so switching models is a valid fix.
  • Incidents are posted. Log the request_id, then check status.claude.com or the Anthropic status page on the Bifrost site before changing configuration.

Claude 529 Error vs 429, 500, and 504

A Claude 529 error reports Anthropic's shared capacity, while a 429 reports your organization's own limits, a 500 an unexpected internal error, and a 504 a request that timed out. Each needs a different wait and fix, so handle errors by status code and error.type together.

Status error.type What it means Whose side Retry it?
429 rate_limit_error Rate limit, ramp limit, or monthly spend cap reached Your account After retry-after; never for a spend cap
500 api_error Unexpected error inside Anthropic's systems Anthropic Yes, unless x-should-retry is false
504 timeout_error Request timed out while processing Anthropic, often long requests Yes; stream long requests
529 overloaded_error API temporarily overloaded across all users Anthropic capacity Yes, with backoff and a budget

Two details are easy to miss:

When Claude Returns 529 Overloaded Errors

Claude returns 529 overloaded errors when traffic to a model exceeds the capacity available for it, which Anthropic ties to high traffic across all users and peak periods. The condition looks different in an API call, a stream, Claude Code, and the Claude apps, and each retries it differently.

A non-streaming request gets an HTTP 529 that the Anthropic SDK retries, while a streaming request gets HTTP 200 and then an overloaded_error event the SDK does not retry

Figure 1: An overload arrives as a 529 status or as an event in a 200 stream, and the SDK retries only the first.

In the Claude API

A non-streaming call gets an HTTP 529. The SDKs retry 408, 409, 429, and 5xx responses up to two times, following retry-after and x-should-retry or backing off from 0.5 to 8 seconds. The Python SDK then raises anthropic.OverloadedError; catch it before InternalServerError, which also matches 500 and 504.

In streaming responses

A stream opens with a 200, so an overload mid-response arrives as an event:

event: error
data: {"type": "error", "error": {"type": "overloaded_error", "message": "Overloaded"}}

The SDK raises APIStatusError with type set to overloaded_error and does not retry. Restart the request only if no text has reached the user yet.

In Claude Code

Claude Code retries transient failures up to 10 times with exponential backoff before it shows API Error: Repeated 529 Overloaded errors, according to its error reference. CLAUDE_CODE_MAX_RETRIES sets the count, CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS caps the 529 backoff (32 seconds by default), and CLAUDE_CODE_RETRY_WATCHDOG=1 keeps CI jobs retrying. Under heavy load it suggests switching models with /model. The full playbook is in our guide to keeping Claude Code working through 529 errors.

In the Claude apps

The Claude apps show a plain-language message instead of a status code; the Claude Desktop app's Code tab reads Opus is experiencing high load. Switch to Sonnet. Check the status page, wait, or pick another model.

How to Choose a Fix for a Claude 529 Error

Choose the fix from the error pattern. Short bursts need only bounded retries, sustained 529s on one model need a fallback model, and workloads that must keep the same model need that model on a second cloud. Most production systems run all three in that order, the layering described in the retries, fallbacks, and circuit breakers guide.

Decision flow: short 529 bursts go to retries with jitter, cases needing the same model go to Bedrock or Google Cloud, and the rest to another Claude model

Figure 2: Retries cover short bursts, a second model covers one model at capacity, and a second cloud keeps the same model.

Work that can wait, such as backfills, belongs on the Message Batches API, which Anthropic positions for workloads outside your normal capacity.

Fix 1: Retry With Exponential Backoff and Jitter

Retrying is the first fix for a Claude overloaded error because most overloads clear within seconds. A sound loop waits longer after each failure, randomizes each wait so clients do not retry together, honors retry-after and x-should-retry, and stops at a fixed budget so a long incident ends in a fallback.

Four attempts against the Claude API separated by random waits of up to 0.5, 1, and 2 seconds, ending in a fallback once the retry budget is used

Figure 3: Each wait window doubles, jitter keeps clients apart, and the loop stops at a fixed budget.

Raise the SDK's max_retries per client or per request with with_options, or own the loop. The AWS Architecture Blog's analysis of backoff and jitter showed that randomized waits cut the calls competing clients make.

import random
import time

import anthropic

client = anthropic.Anthropic(max_retries=0)  # this loop is the only retry layer


def create_with_backoff(max_attempts=4, base=0.5, cap=8.0, **params):
    for attempt in range(max_attempts):
        try:
            return client.messages.create(**params)
        except anthropic.APIStatusError as e:
            should_retry = e.response.headers.get("x-should-retry")
            retryable = e.status_code >= 500 and should_retry != "false"
            if not retryable or attempt == max_attempts - 1:
                raise
            retry_after = e.response.headers.get("retry-after")
            if retry_after:
                delay = float(retry_after)
            else:
                # Full jitter: a random wait inside a window that doubles
                delay = random.uniform(0, min(cap, base * 2 ** attempt))
            time.sleep(delay)

Three choices matter:

  • One retry layer. max_retries=0 turns off SDK retries so attempts do not multiply.
  • 5xx only. It retries 529, 500, and 504 and leaves 429s to their own path.
  • A hard budget. Four attempts mean three waits, at most 3.5 seconds unless retry-after asks for longer.

For how this loop fits with circuit breakers, see our production guide to retries and fallbacks.

Fix 2: Fall Back to Another Claude Model

When 529s on one model outlast the retry budget, send the request to a different Claude model. Capacity is tracked per model, so a second model can have headroom while the primary is overloaded. Test the fallback model on your own prompts first, since it can answer differently.

FALLBACK_MODELS = ["claude-sonnet-5-5", "claude-haiku-5-5"]


def create_with_model_fallback(**params):
    last_error = None
    for model in FALLBACK_MODELS:
        try:
            return create_with_backoff(model=model, **params)
        except anthropic.APIStatusError as e:
            if e.type != "overloaded_error":
                raise  # a 400 or 401 fails on every model
            last_error = e
    raise last_error
  • Fall back on overload only. Validation and authentication errors fail the same way on every model.
  • Check parameters per model. Claude Sonnet 5.5, for example, rejects thinking: {"type": "disabled"} with a 400, while Claude Haiku 5.5 accepts it.

Claude Code has this built in: --fallback-model sonnet,haiku or the fallbackModel setting tries up to three models and returns to the primary on the next message. For the cross-provider version, see automatic fallback when a primary provider fails and failover and load balancing for LLM apps.

Fix 3: Automatic Failover to Claude on Bedrock or Google Cloud

If the output must come from the same model, run the fallback on another cloud. Claude models are available through Amazon Bedrock and Google Cloud, where requests run behind that provider's endpoint with its own status page and error codes, so an overload on Anthropic's first-party API does not have to stop the request.

Platform Claude Sonnet 5.5 model ID Multi-region option
Claude API claude-sonnet-5-5 Managed by Anthropic
Amazon Bedrock global.anthropic.claude-sonnet-5-5, or geo profiles such as us.anthropic.claude-sonnet-5-5 Global and geographic cross-Region inference
Google Cloud (Google managed) claude-sonnet-5-5 Global, multi-region, and regional endpoints

Bedrock's cross-Region inference guide explains the split: geographic profiles keep requests inside a geography such as the US or EU, and global profiles route across all supported commercial Regions. For an availability target, AWS's advice is to "add bounded retries and multi-Region or multi-model fallback" in the application.

In application code, that means a separate client, credential type, and model ID per cloud. The Bifrost AI gateway puts all three behind one Anthropic-compatible endpoint.

The Amazon Bedrock resource page and the setup guides for Bedrock and Vertex AI cover the credentials each cloud needs.

How Bifrost Handles Anthropic Overloaded Errors

The Bifrost gateway classes an Anthropic overloaded error as a transient server failure. It retries the same key with exponential backoff and jitter up to the provider's max_retries, then moves through the fallback chain, and each fallback provider gets its own retry budget. Applications keep the Anthropic SDK and change only the base URL and key.

An Anthropic SDK application sends requests to the Bifrost AI gateway, which retries the Anthropic API on 529 errors, then falls back to Claude on Bedrock and Google Cloud

Figure 4: The application keeps one Anthropic SDK client while Bifrost retries Anthropic, then tries the same model on two other clouds.

The behavior, from retries and fallbacks:

  • Classification. 500, 502, 503, 504, and 529 are transient: same key, backoff of min(retry_backoff_initial × 2^attempt, retry_backoff_max) × jitter(0.8-1.2), with 500 ms and 5,000 ms defaults.
  • Opt-in retries. max_retries defaults to 0; set it per provider in network_config.
  • Ordered fallbacks. Each fallback runs governance, caching, and logging again, and if all fail, Bifrost returns the primary provider's error.
  • Logged attempts. Request logs record every failed attempt with its failure_class, and an Anthropic retry-after is kept as retry_after_ms.

As an LLM gateway, Bifrost adds about 11 microseconds per request at 5,000 RPS, far less than one retry wait.

In Bifrost Enterprise, Adaptive Routing scores providers and keys on live traffic, so a provider failing for a model loses requests that do not name a provider; a closer look at adaptive routing shows what it records.

Step 1: Configure Claude on three providers

Each provider gets a key and a retry budget. The Bedrock alias maps the Claude API model name to an inference profile, and the key inherits AWS credentials from an IAM role:

{
  "providers": {
    "anthropic": {
      "keys": [{ "name": "anthropic-prod", "value": "env.ANTHROPIC_API_KEY", "models": ["*"], "weight": 1.0 }],
      "network_config": { "max_retries": 3 }
    },
    "bedrock": {
      "keys": [{
        "name": "bedrock-prod",
        "models": ["*"],
        "weight": 1.0,
        "aliases": { "claude-sonnet-5-5": "global.anthropic.claude-sonnet-5-5" },
        "bedrock_key_config": { "region": "us-east-1" }
      }],
      "network_config": { "max_retries": 2 }
    }
  }
}

Add a vertex provider the same way, with max_retries: 2 and vertex_key_config holding the project ID, the global region, and credentials. Use a geo profile such as us.anthropic.claude-sonnet-5-5 to keep data in one geography. The Bedrock and Vertex provider docs list every authentication option.

Step 2: Route Claude traffic through a fallback chain

A routing rule sends Claude requests to Anthropic first and names Bedrock and Vertex as fallbacks. A fallback written as "provider/" keeps the incoming model, so one rule covers every Claude model:

{
  "governance": {
    "virtual_keys": [{
      "id": "vk-claude-prod",
      "name": "claude-prod",
      "provider_configs": [
        { "provider": "anthropic", "allowed_models": ["claude-sonnet-5-5"], "key_ids": ["*"], "weight": 1 },
        { "provider": "bedrock", "allowed_models": ["claude-sonnet-5-5"], "key_ids": ["*"] },
        { "provider": "vertex", "allowed_models": ["claude-sonnet-5-5"], "key_ids": ["*"] }
      ]
    }],
    "routing_rules": [{
      "name": "Claude overload failover",
      "cel_expression": "model.startsWith(\"claude-\")",
      "targets": [{ "provider": "anthropic", "weight": 1 }],
      "fallbacks": ["bedrock/", "vertex/"],
      "scope": "virtual_key",
      "scope_id": "vk-claude-prod",
      "priority": 0
    }]
  }
}

The virtual key must allow all three providers, because governance checks every fallback attempt; Bedrock and Vertex carry no weight, so they take no primary traffic. With these budgets, one request makes at most 10 upstream attempts.

Step 3: Point the Anthropic SDK at Bifrost

The application changes its base URL and key. Through the Anthropic SDK integration, responses keep Anthropic's shape, and routing headers report whether a fallback served the request:

client = anthropic.Anthropic(
    base_url="https://bifrost.example.com/anthropic",
    api_key="sk-bf-your-virtual-key",
    max_retries=0,  # Bifrost owns retries and fallbacks
)

raw = client.messages.with_raw_response.create(
    model="claude-sonnet-5-5",
    max_tokens=1024,
    messages=[{"role": "user", "content": "Summarize this incident report."}],
)
message = raw.parse()
if raw.headers.get("x-bifrost-routing-info-is-fallback") == "true":
    print("Served by", raw.headers.get("x-bifrost-routing-info-provider"))

With SDK retries on, a 529 returned after the whole chain fails would run the chain again. A rising fallback rate in these headers, or in AI observability exports to Prometheus and OpenTelemetry, shows the primary degrading early.

Running Claude Code Through Bifrost

The open-source Bifrost gateway connects to Claude Code through ANTHROPIC_BASE_URL, so the same fallback chain covers every coding session. Lower Claude Code's own retries when Bifrost owns them, and keep fallbacks on Claude models so tool use behaves the same on every cloud.

The Claude Code setup for Bifrost uses an env block in ~/.claude/settings.json:

{
  "env": {
    "ANTHROPIC_BASE_URL": "https://bifrost.example.com/anthropic",
    "ANTHROPIC_AUTH_TOKEN": "sk-bf-your-virtual-key",
    "CLAUDE_CODE_MAX_RETRIES": "3"
  },
  "fallbackModel": ["claude-sonnet-5-5", "claude-haiku-5-5"]
}
  • Allow every model Claude Code uses on all three providers, with a Bedrock alias for each; the Claude Code on Bedrock runbook lists sample mappings.
  • Keep both fallback layers. fallbackModel handles one model at capacity, and the Bifrost chain handles the same model on another cloud.
  • Watch retry stacking. Ten Claude Code retries, each running a chain of up to 10 attempts, can hold a turn for minutes.

Frequently Asked Questions

What does 529 overloaded mean on Claude?

A 529 overloaded response means the Claude API was temporarily at capacity and could not take your request. The error type is overloaded_error, and Anthropic notes it can occur during high traffic across all users. The request was valid, so retry it with backoff and jitter, then fall back to another model or cloud if errors continue.

Is Claude down when I get a 529 error?

Not necessarily. A 529 means the model you called is at capacity at that moment, and other Claude models can still answer. Check status.claude.com, or the Claude status page on the Bifrost site, for posted incidents. If nothing is posted, switch models or route the same model through Bedrock or Google Cloud.

Does a 529 error count against my Claude usage limit?

No. Claude Code's error reference states that a 529 is not your usage limit and does not count against your quota. That separates it from a 429, which reports that your organization hit a rate limit, ramp limit, or spend cap. A higher rate limit therefore does not prevent 529s; retries and fallback routing do.

How many times should I retry a Claude overloaded error?

Three to five attempts with exponential backoff and full jitter, capped at about 8 seconds per wait, cover most short overloads. Past that, a fallback model or provider serves the request faster. Keep one layer retrying: if a gateway already retries, set the SDK's max_retries to zero.

Can Priority Tier prevent Claude overloaded errors?

Anthropic's service tiers documentation says Priority Tier requests are prioritized to minimize overloaded errors, even at peak times. Service tiers are now legacy, though: Priority Tier commitments are no longer sold, and only organizations with an existing contract can use them. Teams needing guaranteed capacity are sent to Anthropic sales, so most rely on retries and fallbacks.

Fix Claude Overloaded Errors With Bifrost

A Claude overloaded error is a capacity signal, and the fix is a chain: bounded retries with jitter, a fallback Claude model, and the same model on Amazon Bedrock or Google Cloud. The Bifrost platform runs that chain at the gateway with one Anthropic-compatible endpoint, per-provider retry budgets, and headers that show when a fallback served the request. To see it on your own Claude traffic, book a demo with the Bifrost team.