# Track AI Coding Agent Token Usage on Mac

> Every coding agent counts tokens its own way and shows them in its own place. How to get one view of all of them on a Mac.

- Canonical URL: https://getedith.pro/guides/track-ai-coding-agent-usage-mac
- Published: 2026-12-03
- Updated: 2026-12-03

## The short answer

Most coding agents keep a local record of every request on your Mac, with the model and the token counts. You can read each one with its own tool: `/usage` in Claude Code, `/status` in Codex, the Cursor dashboard, and so on. To see all of them together you need something that reads every agent's records. The free, open source ccusage does that in the terminal. Edith's [Usage](https://getedith.pro/extensions/claude-code-usage) extension does it in a Mac app with charts, live limits and a menu bar readout, and can add agents running on your other machines.

## Why one view matters

If you use one agent, its own usage screen is enough. Most people who use agents daily end up with two or three: Claude Code for one kind of work, Codex for another, an editor agent, maybe a local model in OpenCode. Each has its own plan, its own limits and its own idea of a token. Without one view you cannot answer simple questions: how much did agents do this week in total, which one did most of it, and which project did it go to.

## Method 1: each agent's own tools

Built into each agent

### Ask each agent

Claude Code has `/usage`, with `/cost` and `/stats` as aliases, which shows the session cost, plan limits and activity stats (see Anthropic's [commands reference](https://code.claude.com/docs/en/commands)). Codex shows remaining limits with `/status` and on its usage dashboard, and OpenAI's [Codex pricing page](https://learn.chatgpt.com/docs/pricing) explains how plans are metered. Cursor's plans and usage now live under Grok Build, documented at [docs.grok.com](https://docs.grok.com/build/agents-window/models-and-pricing) (checked December 2026).

These are free and official, and they are the source of truth for your plan. They just do not talk to each other.

## Method 2: ccusage in the terminal

Free, open source

### Run ccusage

[ccusage](https://github.com/ccusage/ccusage) is a free, MIT licensed command line tool. It reads the local logs of a long list of agents, including Claude Code, Codex, OpenCode, Amp, Gemini CLI, GitHub Copilot CLI, Cline and Grok Build CLI, and prints daily, weekly, monthly and session reports with costs estimated from token counts. It runs with no install:

Terminal

Shell

```
npx ccusage
npx ccusage codex daily
```

For a quick report, or on a server without a desktop, it is hard to beat. Free menu bar apps such as CodexBar also cover a very long list of providers if limits are what you care about.

## Where these fall short

- **Reports, not a place to look.** A terminal report is a snapshot. You run it, read it, and it is gone.
- **No limits next to the totals.** Token history and live rate limits come from different tools.
- **One machine.** Agents running on a build box or a home desktop are counted separately, if at all.

## The Edith way: Usage

Usage reads the history that coding agents keep on your Mac and shows tokens and estimated cost by day, model, agent and repository. It finds Claude Code, Codex, Cursor, Grok, OpenCode, Amp, Droid, Codebuff, Hermes, Pi, Goose, Kilo, GitHub Copilot, Gemini, Kimi, Qwen, OpenClaw and Command Code when they have left usage behind, plus Claude Code on the web and Codex cloud tasks through the sign-ins you already have. It reads token counts, model names, timestamps and folders, not your prompts or code.

1. **Install Usage and collect**
   Open Library in Edith, find Usage and press Install. Open the Usage page and press the refresh button in the page header. The first run reads your whole history; on a Mac with months of agent logs it can take a few minutes.
2. **Compare agents side by side**
   The Usage page charts every agent together. The Usage by source over time chart shows each agent as its own series, and the Models card ranks models by tokens and cost. An agent only appears once it has written usage on this Mac.
3. **Narrow it down**
   The filters at the top of the page pick a range, one or more agents, models and folders. Reset filters puts it back to every agent, model and folder for all time.
4. **Add live limits**
   Claude, Codex, Cursor and Grok limits appear as rings with reset countdowns next to the token history. To keep them in view, turn on Show limits in the menu bar in the Limits section of Usage settings, opened from the Settings button in the page header.
5. **Share a month of agent work**
   The share button in the page header (Share usage cards) renders highlights, activity, daily and busiest-day cards as images. They never show repository names, folder paths or dollar amounts.

Costs are estimates

Usage prices each request's tokens, cache reads and writes included, at public API rates. On a flat subscription you never pay that amount. Read it as a way to compare agents, models and days, not as a bill. Some providers, such as Cursor and Grok, report their own cost, which Usage uses as is.

## Count agents on your other machines

Add a server or a second Mac in [Machines](https://getedith.pro/extensions/ssh-machines), then open Usage settings and find the Collected over SSH section. Tick the machines to count and press Collect now. Their agents join your totals with the machine named, and the same repository on two machines still groups into one row. The first collection installs the small tools the collector needs on that machine, including the open source ccusage, so it only runs when you ask.

### From the terminal

Every report is also a command that prints JSON with `--json`, and every command is a tool in Edith's MCP server, so an agent can check its own spend:

Terminal

Shell

```
ed usage sources
ed usage summary --range month
ed usage daily --range month --source codex
ed usage models --range week
ed usage machines collect devbox
```

## Ccusage or Edith?

Use ccusage if a free terminal report is enough, or if you need an agent it reads and Edith does not, such as Cline, Antigravity, ZCode or DeepSeek Harness. Use Edith if you want the numbers on screen all day, live limits beside them, alerts, a project drilldown and your SSH machines in the same totals. Many people use both. Our [ccusage alternative page](https://getedith.pro/alternatives/ccusage) goes through the differences feature by feature.

## Common questions

### Does Edith upload my usage?

Usage history is kept on your Mac, and copied to your iCloud only if you turn on its backup. To read rate limits, Edith calls each provider's usage service with the login you already have, and it fetches Claude Code on the web and Codex cloud usage the same way.

### Can I see Claude Code and Codex in one chart?

Yes. That is the default view. Filter to one agent when you want to look at it alone.

### Which agents can show live limits?

Claude, Codex, Cursor and Grok. Other agents contribute tokens and estimated cost to the history.

## Get started

Usage is part of Edith, a Mac app for macOS 14 or later on Apple silicon, available as a [one-time purchase](https://getedith.pro/pricing). Next, see [Claude Code cost per project](https://getedith.pro/guides/claude-code-cost-per-project), and the agent pages for [Claude Code](https://getedith.pro/agents/claude-code) and [Codex](https://getedith.pro/agents/codex). The [Agents](https://getedith.pro/extensions/coding-agents) board shows the agents themselves while they spend.

## Edith extensions used

- [Claude Code Usage Tracker for Mac: Codex, Cursor](https://getedith.pro/extensions/claude-code-usage): See what your coding agents cost and how close you are to their limits.
- [SSH Server Manager for Mac With Docker and Files](https://getedith.pro/extensions/ssh-machines): Watch, browse and run your servers and containers from one place.
- [Run Multiple Claude Code and Codex Agents on Mac](https://getedith.pro/extensions/coding-agents): See every coding agent on your Macs in one board, and step in when one needs you.

## Related guides

- [How to Check Codex Usage Limits on Mac](https://getedith.pro/guides/check-codex-usage-limits): Check Codex usage limits on your Mac with /status and the ChatGPT usage dashboard, or keep the 5-hour and weekly Codex limits in the menu bar.
- [See Claude Code Cost per Project on Mac](https://getedith.pro/guides/claude-code-cost-per-project): See Claude Code token usage and estimated cost per project on your Mac, worktrees included, for client reports or to find what used up your plan.

## Get Edith

Edith is a native Mac app for macOS 14 or later on Apple silicon with 100+ extensions, the `ed` command line and an MCP server. $35 once for one Mac, plus $7 for each additional Mac, with no subscription and a 30-day refund.

- [Buy Edith](https://getedith.pro/pricing): $35 once for one Mac, plus $7 for each additional Mac
- [Download Edith](https://getedith.pro/download): the installer, or Homebrew
