Optimization5 min read

Why your AI bill doubled this quarter and how to fix it

July 15, 2026

The five usual suspects

When an AI bill doubles in a quarter, it is almost never one big change. It is usually several small ones compounding. Here are the five most common causes.

1. New developers defaulting to flagship models

Every new developer who installs the SDK gets Opus or GPT 5.5 by default. If your team grew from 10 to 15 developers this quarter, that is 50% more flagship-tier calls.

Fix: set a team-wide default model in your SDK configuration. Sonnet handles 70% of tasks equally well at 40% of the cost.

2. Prompt length creep

Prompts grow over time. Developers add more context, more examples, more instructions. A prompt that started at 500 tokens is now 3,000 tokens. That is 6x the input cost per call without anyone noticing.

Fix: audit prompt lengths monthly. Flag any prompt over 2,000 tokens for review. Ask whether all that context is actually improving output quality.

3. Missing prompt caching

If your system prompts repeat across calls but caching is not enabled, you are paying full price for the same tokens every time. On a 3,000-token system prompt sent 100 times per day, that is 270,000 wasted tokens daily.

Fix: enable prompt caching and structure prompts with static content first. Cache-read tokens cost 90% less on Anthropic and OpenAI.

4. Retry loops

Failed API calls that retry automatically can multiply your costs. A 5% error rate with 3 retries means 15% extra calls. If those retries also have exponential backoff with full re-sends, the token cost compounds.

Fix: log retry rates per endpoint. Fix the root cause of failures (usually rate limits or malformed inputs) rather than retrying blindly.

5. Scope expansion without cost review

New features ship with AI calls baked in. Each feature adds 5-10% more API volume. Over a quarter, three new features can add 20-30% to the bill without anyone flagging it as a cost event.

Fix: add cost impact to the feature review process. Before shipping a new AI-powered feature, estimate the monthly API cost at projected usage levels.

How to diagnose which one hit you

Pull your call volume and average cost-per-call for the last 90 days. If call volume went up but cost-per-call stayed flat, it is developer growth or scope expansion (causes 1, 5). If cost-per-call went up but volume stayed flat, it is prompt creep or missing caching (causes 2, 3). If both went up, check for retry loops (cause 4).

Run a free cost breakdown at /teardown or start tracking with the free dashboard.

Track your real costs

Calculators estimate. The dashboard shows what you actually spend and where you can save.