Of eight AI vendors we checked on October 3, 2026, six let a team set a cap that stops usage when spend reaches it. Microsoft’s Azure budgets only send alerts, and AWS stops usage only if you wire up a budget action yourself. Even the real caps can overshoot, because billing data arrives minutes to hours late and long-running jobs finish after the line is crossed.
- 01Alerts are not capsAzure budgets, OpenAI spend alerts and GitHub seat budgets notify you; they do not stop anything.
- 02Most APIs can stopAnthropic, OpenAI, Google and OpenRouter can stop usage at a cap you set.
- 03Caps run lateOpenAI and Google both warn that spend can pass the cap before enforcement catches up.
- 04Scope mattersPer-project, per-key and per-user caps contain one runaway job; an account cap stops everything.
01 — ContextCaps, alerts and actions are different things
“Spend control” covers three mechanisms, and vendors use the same words for all of them. The difference only shows on the day an agent loops overnight.
Hard cap
Requests fail with an error once spend reaches the limit, until the period resets or someone raises it.
Alert
An email or notification at a threshold. Traffic carries on.
Automated action
A rule that changes permissions when a threshold is hit, which can block further use if you design it to.
02 — The dataEight vendors compared
The table covers the controls each vendor documents for its AI products or, for Azure and AWS, the account-wide cost tools that cover their AI services.
| Vendor | Can it stop usage? | Scope | What happens at the cap |
|---|---|---|---|
| Anthropic Claude API | Yes | Organization and workspace; per session for Managed Agents | Tier cap: HTTP 429 with no retry-after until the 1st of next month. Your own limit: HTTP 400. Agent session pauses, in-flight request finishes |
| OpenAI API | Yes, if you turn on a hard limit | Organization and project | HTTP 429 with a spend-limit code; can slightly overshoot; resets monthly. Alerts never stop traffic |
| Google Gemini API | Yes | Billing-account tier cap and per-project caps (experimental) | Overage possible: billing data can lag about 10 minutes, and batch jobs and agent sessions can run past the cap. Not for invoiced accounts |
| Microsoft Azure budgets | No | Subscription, resource group or wider scopes | Email alerts, or an action group that can call your own automation; Microsoft says consumption is not stopped. Costs evaluated every 24 hours |
| AWS Budgets | Only through a budget action | Account or organization | An action you configure can apply an IAM policy or service control policy, automatically or after approval |
| GitHub Copilot | For metered AI credits, not seats | Enterprise, organization, cost center, repository or user | Metered usage can be stopped at the budget; seat licenses only get alerts |
| Cursor Teams | Yes, team-wide | Team; per member on Enterprise | Limits apply to on-demand usage after included usage, which is on by default |
| OpenRouter | Yes | Account balance and each API key | HTTP 402 naming the limit that was hit; per-key limits can reset on a schedule |
Two newer controls stand out. OpenAI added hard spend limits for organizations and projects on July 22, 2026. Anthropic added session budgets for Claude Managed Agents (in beta) on August 7, a dollar cap on one agent session priced at public list rates. A paused session keeps its history and can resume if the budget is raised.
GitHub’s budgets documentation draws the line most teams miss: a budget on a seat license such as Copilot only warns, while a budget on metered Copilot AI credits can stop usage, and can be set per user.
03 — The defaultsCaps you get without setting anything
Anthropic and Google also apply a monthly ceiling by account tier, whether or not you set your own. Reaching one affects every app on the account, not just the one that caused it.
- Google Gemini API, Tier 1Billing account linked
- $250 / month
- Anthropic, Start tierMonthly spend cap
- $500 / month
- Anthropic, Build tierMonthly spend cap
- $1,000 / month
- Google Gemini API, Tier 2$100 paid and 3 days since first payment
- $2,000 / month
- Google Gemini API, Tier 3$1,000 paid and 30 days since first payment
- $20,000 to $100,000+
- Anthropic, Scale tierCustom tier has no cap
- $200,000 / month
Anthropic’s rate limits page says that once an organization reaches its tier cap, the API returns HTTP 429 until midnight UTC on the first of the next month, with no retry-after header, so automatic retries keep failing. OpenAI separately assigns each organization an approved monthly usage limit by tier, distinct from the limits a team sets.
04 — The catchWhy even hard caps overshoot
Caps are only as fast as the billing data behind them. OpenAI says enforcement is not instantaneous and recorded spend can slightly exceed the limit. Google’s Gemini API billing page puts the lag at up to about 10 minutes and warns that batch jobs and agent sessions can run past a project cap. Azure’s budget alerts rely on cost data that typically arrives 8 to 24 hours late and is evaluated every 24 hours.
Anthropic’s session budgets show the same effect at small scale: the check happens between model requests, so the request that crosses the cap still completes. OpenRouter takes the opposite approach for concurrent traffic on smaller prepaid balances, estimating each paid request’s token cost up front and refusing new requests once the running ones fill an in-flight budget set as a fraction of the balance.
If the most you can afford to lose in a month is $5,000, do not set the cap at $5,000. Leave room for an hour or a day of overshoot at your peak spending rate, and set alerts well before the cap so a person sees the trend first.
05 — Practical implicationsA spend setup that holds
A cap is the last line, not the plan. The first is knowing what each workflow should cost, which our agent token budget framework covers, and the second is prices that can change under you, which our Q3 price change tracker follows. For long agent runs specifically, see budgeting long-horizon agent runs. Teams that want caps, alerts and per-workflow budgets designed together can work with our AI transformation team.
06 — The testA sandbox test for your cap
The conclusion says to test what your cap does before you need it, and the test is small enough to describe in full. Create a separate project, workspace or key on the vendor in question, so the test cannot touch production spend. Set the lowest cap the vendor allows. Point a copy of your real application at it, including the retry logic and the error handling it ships with, and run a loop that will cross the cap in minutes rather than hours.
Then watch three things. What the vendor returns when the cap is reached: Anthropic’s rate-limits page documents a 429 with no retry-after on its tier cap and a 400 that states when access resumes on a limit you set yourself, and other vendors differ. What your application does with that response: retries, surfaces an error, fails silently, or treats it as a bad prompt. And how far past the cap the recorded spend goes before the responses change, which is the overshoot the lag section describes, measured on your own traffic pattern.
Write the three answers down with the date and the vendor’s documentation version. The test is cheap to repeat, and it should be repeated whenever the retry logic changes, because a cap is only as good as the code that meets it.
07 — The handlerWhat your code should do at the cap
A cap turns a billing problem into an error-handling problem, and an application written before the cap existed may not handle that error. The response at the cap is not a transient failure that a retry will clear, and it is not a malformed request that a different prompt will fix. It is a stop, and the code should treat it as one: no automatic retry on a spend-limit error, a clear log line naming the limit, and a human notification that is distinct from any alert the vendor sends.
The two cases the table warns about need separate handling. A 429 with no retry-after header, as Anthropic’s rate-limits page describes for its tier cap, will keep failing until the month resets, and Anthropic’s page says retrying, including the SDK’s automatic retries, fails until access resumes. A 400 that states when access resumes, on a limit you set, carries the resumption time in the response, and the right behavior is to park the work until then rather than to report a bad request.
For long-running agents the handler also has to decide what happens to the task in flight. Anthropic’s session budgets pause a session and keep its history so it can resume if the budget is raised; a workflow built on another vendor has to preserve that state itself. The question to answer in the design is the same one our recovery guide for expired connectors asks: for each item the loop was working on, what is known about its state when the cap fires?
08 — The failuresFour caps that did not hold
Each illustrative case below is a team that set a spend control and still met the bill it was meant to prevent. They map onto the three mechanisms in the first section and the lag in the fourth.
The alert read as a cap: an Azure budget is set at the month’s limit and the team assumes usage stops there, when Microsoft says budget alerts do not affect resources or stop consumption. The cap set at the limit: a hard cap is set at exactly the amount the business can afford to lose, with no room for the minutes-to-hours lag the vendors themselves document, and the overshoot is the one line nobody budgeted. The account-wide stop: several apps share one API account under one cap, a test loop in one of them hits it, and every production app on the account returns errors until the period resets. The retry storm: a spend-limit 429 with no retry-after is fed to a generic retry handler, which retries on a schedule of its own, so the cap holds the spend and the logs fill with thousands of identical failures.
The routing in the setup section prevents the third, the callout above prevents the second, the first section prevents the first, and the handler section prevents the fourth. None needs a new vendor feature; all need the test above to have been run once.
Does it stop usage or only tell us, and what does our code do with the response when it does? If either answer is “we think so”, the sandbox test is the next task.
Test what your cap does before you need it
In a sandbox project, set a tiny cap, run a loop past it and watch what your application does with the error. A cap that turns into a silent retry storm, or a 400 your code treats as a bad prompt, is worse than an alert.