How do I cap my AI API bill? Claude and Gemini spend limits
Ship ItChecked against the official source
Source checked 3 Oct 2026 · Published 3 Oct 2026 · Last reviewed 3 Oct 2026 · By Ctrl+Z Therapy (how we test)
The short answer
Set a spend cap, not just an alert. On the Claude API, you set a monthly spend limit for each workspace in the Console, but you can't set limits on the Default Workspace, so make a workspace for your app. On the Gemini API, you set a monthly spend cap per project in AI Studio; Google notes that billing data runs about 10 minutes behind, so charges can go past the cap.
What to do
- Claude: create a workspace for your app, then set its monthly limit on the Spend limits tab.
- Gemini: in AI Studio, open the Spend page and edit the monthly spend cap.
- Other providers: look for a hard cap in billing, not just an alert.
- Keep the API key on your server, never in the browser.
Source
Checked on 3 Oct 2026. Prices, limits and settings change, so check the source before you rely on them.