← Blog

Claude API Spend Tracking Spreadsheet Template

2026-10-01 · 5 min read · SubToAPI Team

If you're searching for a Claude API spend tracking spreadsheet template, you probably already have a cost problem: either a surprise invoice, a team that doesn't know who's burning tokens, or a finance person asking "what are we actually paying for." This article gives you a working template structure you can copy into Google Sheets or Excel today, plus the formulas to make it actually useful instead of a column of numbers nobody updates.

The short version: track spend by date, model, project/feature, input tokens, output tokens, and cost, roll it up with pivot tables by week and by project, and set a conditional-formatting threshold so overspend is visible at a glance. Below is the full layout, the formulas, and where manual tracking breaks down — plus a faster alternative if you're past the spreadsheet stage.

The core columns

A Claude API spend tracker needs more granularity than "total spent this month." At minimum, each row should represent one request or one daily rollup per project:

| Column | Example | Notes | |---|---|---| | Date | 2024-05-14 | Daily granularity minimum | | Project/Feature | support-bot | Where the call came from | | Model | claude-opus-4 | Pricing differs per model | | Input tokens | 12,400 | From API response usage field | | Output tokens | 3,100 | Same | | Cost per 1M input | $15.00 | Lookup table, update when pricing changes | | Cost per 1M output | $75.00 | Same | | Computed cost | =((Input/1000000)CostIn)+((Output/1000000)CostOut) | | | Owner | jane@company.com | For team accountability |

Keep model pricing in a separate lookup tab so a pricing change is one edit, not a find-and-replace across thousands of rows.

Formulas that make it useful

A column of costs is a ledger, not a tracker. Add these on top:

Daily total:

=SUMIFS(CostColumn, DateColumn, TODAY())

Month-to-date by project:

=SUMIFS(CostColumn, ProjectColumn, "support-bot", DateColumn, ">="&EOMONTH(TODAY(),-1)+1)

Burn rate alert (conditional formatting rule): Highlight the daily total cell red if it exceeds (MonthlyBudget / DaysInMonth) * 1.5 — this catches spikes early instead of at month close.

Forecast to end of month:

=(MonthToDateCost / DAY(TODAY())) * DAY(EOMONTH(TODAY(),0))

This single formula is the one most teams skip, and it's the one that actually prevents surprise invoices — it extrapolates your current burn rate forward instead of just showing what's already spent.

Where the data comes from

This is the part that breaks every manual spreadsheet. The Claude API response includes a usage object with input_tokens and output_tokens per request, but getting that into a spreadsheet means:

In practice, most manual trackers die within a month because someone forgets to log usage for a new feature, or a teammate calls the API directly without going through the logging wrapper. By the time finance asks about the invoice, half the rows are missing.

A lighter-weight alternative

If you're tracking spend because multiple people or projects share one Claude account, a spreadsheet is solving a symptom. The underlying problem is usually: no per-project API keys, no built-in usage metadata, and no single dashboard to see spend without exporting anything.

SubToAPI turns your existing Claude access into an HTTPS API with application-level keys (sub_live_...) per project or per team member, and every request returns usage metadata you can log or just view in the dashboard — no export-and-paste step required. If you're already building the spreadsheet in this article because you have multiple apps or teammates hitting Claude under one account, issuing separate keys per project through /docs/quickstart gives you the same breakdown the spreadsheet is trying to reconstruct, without the maintenance.

For teams, that also means seat-based access control — Solo, Team, and Scale plans on /pricing — so spend is attributable by key from day one instead of inferred after the fact.

Keeping the spreadsheet accurate if you stick with it

If you're not ready to change your setup, these three habits keep a manual tracker honest:

  1. Log usage at the call site, not after the fact. Wrap every Claude API call in a function that writes {date, project, model, input_tokens, output_tokens} to a log immediately. Retrofitting logging later always misses calls.
  2. Reconcile against the Anthropic invoice monthly. Your spreadsheet total should match the billing statement within a small margin. If it doesn't, you have untracked calls somewhere.
  3. Separate test/dev traffic from production. A dedicated environment column prevents local testing from inflating your "real" spend numbers and skewing the forecast formula.

When a spreadsheet stops being enough

A spreadsheet works fine for one person running occasional scripts. It stops working once you have:

At that point the maintenance cost of the spreadsheet exceeds the cost of just giving each project its own key and reading usage from a dashboard built for it. SubToAPI's /docs/messages and /docs/streaming endpoints return the same usage data your spreadsheet formulas are trying to compute manually, attached to the specific key that made the call.

questions

Do I need a spreadsheet if I only use Claude personally? Probably not. Personal usage rarely needs row-level tracking — checking your Anthropic billing dashboard monthly is enough. Spreadsheets earn their keep once multiple projects or people share the same account.

How do I get token counts to put into the spreadsheet? Every Claude API response includes a usage object with input_tokens and output_tokens. You need to capture and log this at the point each request is made — there's no way to retroactively pull historical token counts from Anthropic.

Can I track spend per project without building a spreadsheet at all? Yes — issue a separate API key per project or team member through a proxy like SubToAPI (/signup), and read per-key usage directly from the dashboard instead of logging and reconciling manually.

Turn your Claude access into an HTTPS API

SubToAPI gives you application API keys, streaming, tool use and usage insights on top of your existing Claude access — set up in minutes.

Start free  Read the quickstart →