GPT-4o Not Working
Errors, timeouts, or GPT-4o works in ChatGPT but not the API? Here’s how to tell if OpenAI is down and how to fix the most common GPT-4o failures.
Prismix probes OpenAI every 5 minutes. The official status page typically lags real incidents by 10–20 minutes.
What error are you seeing?
429 Too Many Requests
You hit a rate limit (requests per minute or tokens per minute). Add exponential backoff to your code. You can also upgrade your usage tier at platform.openai.com/account/limits.
401 Invalid API Key
The API key is wrong, revoked, or has been rotated. Go to platform.openai.com/api-keys, create a new key, and update it in your app’s environment variables.
503 / 500 Server Error
OpenAI infrastructure is overloaded or experiencing an incident. Check live OpenAI status. These resolve on their own — implement retry logic (3 retries, 2× backoff) to ride out short incidents.
Works in ChatGPT but not the API
ChatGPT and the API are separate systems. Check your API key, billing balance, and that your account’s usage tier allows GPT-4o access. The ChatGPT interface never uses your API key.
Response cuts off mid-generation
You likely hit the max_tokens limit. GPT-4o defaults vary by API version — set max_tokens explicitly (up to 16,384 for GPT-4o). Also verify your prompt isn’t consuming most of the context window.
5 fixes to try in order
Check live OpenAI status
Visit prismix.dev/service/openai. If OpenAI is degraded or investigating an incident, nothing on your end will fix it — set up an alert and wait. Prismix detects outages before the official status page.
Check billing and usage
Go to platform.openai.com/account/billing. Confirm your credit balance is positive and your payment method is valid. API calls stop working immediately when credits run out — there’s no grace period.
Verify model name and key
Ensure you’re using model: "gpt-4o" (not gpt4o or gpt-4-o). Regenerate your key at platform.openai.com/api-keys if you suspect it’s stale. Keys don’t expire but can be revoked by account policy changes.
Add retry with backoff
For 429 and 5xx errors: retry up to 3 times with delays of 1s, 2s, 4s. The OpenAI Python and Node SDKs have built-in retry logic — enable it via max_retries=3. Most transient failures resolve within two retries.
Fall back to another model
If GPT-4o is unavailable, gpt-4o-mini is usually up when GPT-4o is not — they run on separate infrastructure. For a cross-provider fallback, claude-sonnet-4-5 via api.anthropic.com covers most GPT-4o use cases.
Get alerted the moment OpenAI recovers
Free email alerts from Prismix — know instantly when GPT-4o comes back from an outage. No account required to check status.
FAQ
Is GPT-4o free?
GPT-4o is available on the free ChatGPT tier with usage limits. Via the API it costs per token — check openai.com/api/pricing for current rates. GPT-4o mini is significantly cheaper for high-volume workloads.
GPT-4o vs GPT-4o mini — which should I use?
GPT-4o mini is faster and cheaper, suitable for most tasks. Use full GPT-4o for complex reasoning, nuanced writing, or when you need the highest quality output. They run on separate infrastructure so one being down doesn’t mean the other is.
Why does GPT-4o have a context limit error?
GPT-4o has a 128K token context window. If your prompt + history exceeds this, you’ll get a context length error. Truncate conversation history, summarize earlier messages, or split into multiple calls.