API errors
Free LLM API errors, explained from the official docs.
Each page says what the error means, the documented causes and how to tell them apart, the fix, and what changes when a router can send the request to another free provider.
- OpenRouter OpenRouter 402 OpenRouter returns 402 when your balance, a key's credit limit or the in-flight budget cannot cover a request. A negative balance blocks :free models too.
- OpenRouter OpenRouter 429 OpenRouter :free models allow 20 requests a minute and 50 or 1,000 a day. How to tell that cap from an upstream 429, and what to do about each.
- Gemini API Gemini 429 RESOURCE_EXHAUSTED A Gemini 429 RESOURCE_EXHAUSTED means your project went over a rate limit: requests or tokens per minute, or requests per day, which reset at midnight Pacific.
Before you retry
A negative balance needs credits and a daily cap lasts until its reset. OpenRouter's
in-flight-budget 402 is the exception: wait for its Retry-After before retrying.
The LLM fallback guide sorts errors by
what to do next, and the free-tier tracker lists each provider's
published limits.