For VS Code & JetBrains IDEs · Copilot · Copilot CLI · Claude Code

Know exactly what your AI coding tools cost.

GitHub's billing page gives you one account-level total. Copilot Cost Lens reads the logs Copilot, the Copilot CLI and Claude Code already keep on your machine, attributes every request to the repository you were in, prices it by model — and turns it into a live dashboard and a status-bar ticker. Per repository, per model, per day. 100% local.

  • 100% local — no network requests, no telemetry
  • Per repository, per model, per day
  • Free & open source
What it does

The per-repository breakdown your bill can't give you.

Since Copilot moved to usage-based AI Credits, the question isn't "how many requests?" but "which project is burning my credits, on which model, and will I fit my allowance?" Here are the answers, in your editor.

№ 01

Cost per repository

Every chat request is attributed to the workspace it ran in and resolved to an owner/repo slug from the project's git remote — so you see exactly which project spent what.

№ 02

Every AI tool, one ledger

VS Code Copilot Chat, the Copilot CLI agent and Claude Code transcripts in a single view, with a per-provider split. Claude Code is shown but never counts against your Copilot allowance.

№ 03

Budgets, forecasts & alerts

An allowance gauge, end-of-month forecast, month-over-month trend and a projected allowance-exhaustion date. Set credit and dollar budgets; the status bar turns orange before you blow them.

№ 04

Model & token anatomy

Input, output, and cache read/write tokens per repository, the exact models used, a cost-by-model donut, cache-read share, and the effective blended $/1M you're really paying.

№ 05

Drill-downs, projects & receipts

Open any repo for model mix and daily trend, roll repos into named projects, star the important ones, browse an all-time view and activity heatmap — and export a printed-receipt PDF for chargeback.

№ 06

Built for 100+ repos

Instant text filter, source chips, sortable columns and starred repos pinned on top. One-click CSV/JSON export, multi-editor scanning, and a UI localized in English, Čeština, Deutsch and 日本語.

Editions

One ledger, native to your IDE.

The same engine and the same dashboard in two editions — a VS Code extension and a JetBrains IDE plugin (built on JCEF, so it looks and behaves identically). Pick your editor; the numbers come out the same.

On the Marketplace

JetBrains IDEs

IntelliJ IDEA · WebStorm · PyCharm · GoLand · Rider & more · 2024.3+

  • One-click install from the JetBrains Marketplace
  • The same dashboard, rendered with JCEF
  • At feature parity with the VS Code edition
Install from Marketplace
How it works

It reads the logs your tools already keep.

No new agent, no proxy, no account. Cost Lens combines the local telemetry your AI tools already write to disk, prices it, and presents it. When exact billed data exists it's used; estimates are always labelled ~est.

Reads

What's already on disk

VS Code Copilot transcripts and debug logs, the Copilot CLI session-state, and Claude Code transcripts — most with exact token counts and billed AI-credit units per request.

Prices

Every request, by model

Billed AI-credit units when present, otherwise exact tokens × a built-in model price table covering GPT, Claude, Gemini, Grok and more. Every rate is overridable — no waiting for an update when pricing changes.

Shows

Answers, not raw logs

A live dashboard, a status-bar ticker with a 7-day sparkline, per-repo and per-project drill-downs, and CSV/JSON/PDF exports for invoicing and chargeback.

Cost Lens is an independent open-source project, not affiliated with GitHub or Microsoft. The log format isn't a stable public API, and the figures are an analytical aid, not a bill — your GitHub billing page remains the source of truth.

Privacy

Your costs never leave your machine.

Spend data is sensitive, and Cost Lens treats it that way. Everything happens locally — there's simply nowhere for your numbers to go.

No network

Cost Lens makes zero network requests. It reads local files only — your VS Code workspace storage and the Copilot CLI / Claude Code stores in your home directory.

No telemetry

Nothing is collected, phoned home, or shared with anyone — including the author. There is no account to create and no data to opt out of.

Never runs git

Repository names are read from workspace.json and .git/config as plain files. Cost Lens never executes git or any other command on your machine.

FAQ

Questions, answered.

Does any of my code or usage data leave my machine?

No. Cost Lens reads local log files only, makes no network requests, and collects no telemetry. There's no backend and no account — your numbers stay on your computer.

Which tools and editors does it track?

GitHub Copilot Chat, the Copilot CLI, and Claude Code, with an opt-in source for JetBrains Copilot. It automatically scans VS Code, VS Code Insiders, VSCodium, Cursor and Windsurf storage.

Will the numbers match my GitHub bill exactly?

They're an analytical aid, not a bill. Cost Lens uses billed AI-credit units when the logs contain them and prices the rest from a model-rate table. The log format isn't a stable public API, so treat your GitHub billing page as the source of truth.

How does it know which repository a request belongs to?

It resolves the workspace to an owner/repo slug by reading workspace.json and .git/config as plain files — it never executes git. Requests without a remote are grouped by folder.

Is there a JetBrains edition?

Yes — a native plugin for IntelliJ IDEA, WebStorm, PyCharm, GoLand, Rider and the rest of the JetBrains family (2024.3+, Java 17). It renders the same dashboard through JCEF and is at feature parity with the VS Code edition. Install it from the JetBrains Marketplace (source on GitHub). Either edition reads the same on-disk logs, so they report identical numbers — and both scan VS Code, Insiders, VSCodium, Cursor and Windsurf storage out of the box.

How much does it cost?

It's free and open source — install it from the VS Code Marketplace or browse the code on GitHub.

See where your AI credits go.

Install in under a minute. Your historical sessions are picked up on the first scan, so the dashboard has something to show the moment it opens.

Install for VS Code   Get for JetBrains