brave search api 429 rate limit exceeded
Handles Brave Search API 429 rate limit errors: honor Retry-After, add exponential backoff, cap concurrency, and check plan quota. Use when Brave search calls return 429 or rate limit exceeded in a loop or crawl. Not for 401/403 auth errors or 429s from a different API.
TL;DR
429 means you are over Brave's per-second or monthly query cap. Read the Retry-After response header, back off, and reduce your request rate. If you keep hitting it at low rates, the key is on the wrong plan or shared across too many callers.
brave search api 429 rate limit exceededUse this when
- The Brave Search API returns HTTP 429 on search requests.
- You see
rate limit exceededin the error body. - A crawl or agent loop hammers the API in a tight loop.
Not for this skill when
- The status is 401 or 403. Those are auth and plan problems, not rate problems.
- The 429 comes from a different API. Each provider's headers differ.
Steps
- Capture one full response: status, body, and headers. Verify: you can see the exact plan message, not just the code.
- Read the
Retry-Afterheader and wait that many seconds before retrying. Verify: the retry returns 200. - Add exponential backoff in your client: sleep 1s, 2s, 4s up to 60s on each 429. Verify: a burst of 20 queries completes without a second 429.
- Cap concurrency: one in-flight request at a time per key, with at least 1s between calls on the free tier. Verify: sustained traffic stays under the limit.
- If 429s persist at one request per second, check the plan dashboard for monthly quota. Verify: usage is under the plan cap; if it is over, upgrade the plan or give each caller its own key.
Variant phrasings
brave api rate limit
Same handling, shorter query.
429 brave search
Short form of the same error.
brave search quota exceeded
The monthly-cap variant of the same error.
Compatibility: Brave Search API v1 (api.search.brave.com). Free tier caps are per-second and monthly; paid tiers raise both.
Why it happens
Brave enforces two limits: a burst limit (requests per second) and a monthly quota. Tight retry loops and parallel workers burn through the burst limit instantly, and shared keys across developers burn the monthly quota. The 429 is the API telling you to slow down, not a bug to route around.
Edge cases / pitfalls
- Retrying immediately on 429 doubles the load and extends the block. Always honor Retry-After first.
- Keys shared across a team hit the quota with no single heavy caller. Give each service its own key.
- Cache repeated queries locally. Search results for the same query rarely change minute to minute.
Provenance
Resolved from the public thread: https://vectle.com/posts/pst_4cAGTAz2mk3Uh9jxNyMVOg
Maintainer review
No maintainer verification is recorded for this version.
This records the version a maintainer checked. It does not assert that the version is the latest upstream release.