$ claude-code-session-tracker
NewAuto continue — sessions pick up after a limit resets

Local · open source · zero dependencies

Get more out of every Claude Code session.

Every Claude Code session on one page — which one is waiting on you, what each is spending, and how much of your limits is left.

npx claude-code-session-tracker@latest

Then open the printed http://127.0.0.1:3099.

7stars
1.5Kdownloads / month
v0.13.0latest

Node 20 or newer · macOS, Linux, and Windows

Demo

See it in 30 seconds

Live sessions, limits and history, on a real machine.

Auto continue

New

Hit the limit, walk away — it picks up when the limit resets

A session that stopped on a usage limit continues by itself about a minute after the limit resets. No more coming back to a session that sat idle for hours.

5-hour limit

100%

Session

⏸ waiting
⏵ continued
+1m
2:00pm2:47pm3:00pm
  1. Working

    The session runs until the five-hour limit fills.

  2. Stopped at 100%

    Claude Code refuses the turn; the plugin's hook starts waiting.

  3. Waiting for the reset

    The page and the menu bar list it, with the time it continues.

  4. Continues by itself

    A minute after the reset, Claude Code wakes it and it carries on.

A timeline: the session works while the five-hour limit climbs to 100%, stops when it fills, waits until the limit resets, and continues on its own a minute later. Invented times.

In Claude Code, add the plugin that carries the hook:

/plugin marketplace add meyusufdemirci/claude-code-session-tracker
/plugin install session-tracker@claude-code-session-tracker

Then turn it on:

claude-code-session-tracker auto-continue on

Off until you turn it on — on the Settings page, under a full limit on the dashboard, in the macOS menu bar, or with the command above. Needs the plugin at 0.13.0 or later, and only sessions started after it is installed carry the hook.

To turn it off:

claude-code-session-tracker auto-continue off
> Add the export dialog

  ⎿  Usage limit reached · resets 3:00pm

  ⏸  Waiting for the reset · continues at 3:01pm

  ⏵  The usage limit that stopped this session has reset;
     continue the task you were working on

  ●  Picking up the export dialog where I left off…
A session that stopped on the five-hour limit. Invented times.
  1. Any terminal

    Claude Code wakes the session itself, so it works the same in VS Code, Ghostty, tmux, iTerm or Terminal.

  2. Nothing else has to run

    The wait lives inside the session. No tab, menu bar or tracker needed — just leave the session open.

  3. Checked before it wakes

    At the reset it makes sure the switch is still on, that you have not carried on yourself, and that the limit no longer reads as full.

  4. Weekly limits too

    A session can wait up to eight days. Turning it on while sessions are already waiting still covers them.

Preview

The page it opens

Limits on top, sessions below, and details for any row you open.

Claude Code

Sessions

LiveUpdated 16:49:12

Session limit 14:30 → 19:30

Resets 19:30 · 2h 41m left

58%
Used
1.9M
At this pace
Limit 18:52

At the last hour's pace you'll hit the limit at 18:52, 38m before it resets. Anthropic's reading of this five-hour window, 2m ago.

Weekly limit 18 Aug → 25 Aug

Resets Mon 25 Aug, 03:00 · 2d 10h left

59%
Used
31.4M
At this pace
88% at reset

Every model. Anthropic's reading of this week, 2m ago.

Last 7 days

Long sessions
3.1M

3 sessions ended several times larger than the 128K this machine usually reaches. Every turn after that re-reads the whole window.

acme-web · 214 turns · 62.4K → 604.1Kbilling-api · 168 turns · 58.1K → 511.7K

Standing context
1.6M

Sessions open holding 74.3K — the system prompt, tools, skills and memory files, paid before anything is asked.

38 sessions

Ranked by what each accounts for, in the tokens a limit counts. A finding appears only where the range runs heavier than this machine's own middle.

Active 3

ProjectSessionStatusModelTokens (in/out/total)Uptime
acme-web~/code/acme-webRework the checkout flow279ed6aebusyopus-5182.4K / 12.9K / 195.3K1h 24m
billing-api~/code/billing-apiPaginate the invoices endpointb41c7d02waitinginput neededsonnet-596.2K / 7.4K / 103.6K18m 42s
design-system~/code/design-systemTidy the button variants5f2a91c4idlesonnet-541.8K / 3.1K / 44.9K3h 06m

Recent 5

ProjectSessionModelLast activeTokens (in/out/total)
acme-web~/code/acme-webFix the flaky checkout testit only fails on CI, never on my machineopus-512m ago214.7K / 15.3K / 230.0K
mobile-app~/code/mobile-appRetry the offline write queueflush the queued writes once the connection is backsonnet-52h ago158.9K / 11.2K / 170.1K
docs-site~/code/docs-siteAdd dark mode to the docsauto, light and dark, and no flash on first paintsonnet-55h ago88.4K / 6.1K / 94.5K
billing-api~/code/billing-apiRotate the webhook secretmove it to the secret store and re-sign the callbackshaiku-4-5yesterday23.1K / 1.9K / 25.0K
acme-web~/code/acme-webWindows CI: separators in the path testthe path assertions only hold on posixopus-53d ago61.2K / 4.4K / 65.6K

50 of 794 on disk

Read-only. Bound to loopback. Nothing leaves this machine.

Fully interactive, with invented data. Swipe a table to see the rest of it.

Open any row

Tokens, context left, prompts, and a resume command to copy.

Static context shows what fills the window before you type — CLAUDE.md, skills, tools, MCP — the part you can actually shrink.

Every figure comes straight from the transcript. Nothing is guessed.

acme-web

Rework the checkout flow

busy

Tokens

Input
182,411
Output
12,907
Total
195,318
Cache read
4,182,660
Cache write
311,204

Context window

Static (system + tools)
41.2K
Conversation
154.1K
Free
804.7K

19% of 1M tokens · opus-5

Static context

  1. ~/code/acme-web/CLAUDE.md18,214 · 44%
  2. Skills (32)9,431 · 23%
  3. Deferred tools (86)5,102 · 12%
  4. Agents (11)3,608 · 9%
  5. MCP instructions2,417 · 6%
  6. Everything else2,435 · 6%

41,207 tokens before the first turn ran, estimated from the text each block put in the window.

What this session cost

Its 38 turns read 4.2M back out of cache between them. Those reads bill at a fraction of the rest, so they sit outside the totals above.

The window an average turn held
110.1K
Of it, static — read back every turn
41.2K
Subagents, billed here but not shown
2

Session

Model
opus-5
Started
14:12
Last active
just now
Elapsed
1h 24m
Working time
38m 09s

Limits

How much of each window is left

Two windows, five hours and seven days. Each card shows how full it is and when it runs out at your current pace.

  1. The same percentage /usage shows

    Anthropic's own reading of each limit, the same number /usage shows.

  2. Used is what you were billed for

    Input, output and new cache tokens, across every project and subagent. Cache reads are shown apart.

  3. At this pace, it runs out at…

    Based on your recent pace, the card says when the window runs out — or where it will stand at reset.

  4. Two ticks on the bar

    Red is time elapsed, blue is where you'll land. Fill past the red tick means you're spending too fast, and the bar turns red.

Offline or without a fresh reading, the bar falls back to your heaviest past window — and says so.

Alerts

Told before you hit a limit

A desktop notification before a window runs out. Off by default.

http://127.0.0.1:3099/settings

Claude Code

Settings

SessionsHistorySettings

Notifications

A desktop notification before a window runs past its limit.

Session limitThe five-hour window.
At most one every1 hour
Weekly limitThe seven-day window.
At most one every4 hours

Session limit

now

127.0.0.1:3099

At the last hour's pace you'll hit the limit at 18:52, 38m before it resets.

Hear about a limit before you reach it

A desktop notification when a window is on course to run past its limit — even with this tab behind your editor.

Not nowOpen notifications
  1. Off until you turn it on

    Nothing asks for permission until you flip a switch.

  2. Once, then quiet

    One per interval: an hour for the session, four for the week.

  3. Offered once

    Suggested once when a limit first appears.

A week with no reset from Claude stays silent.

History

Where the tokens actually went

A second page with your tokens by day, hour, project and model — plus your year at a glance, a report to export, and a picture to share.

http://127.0.0.1:3099/history?range=30d

Claude Code

History

SessionsHistorySettings
RangeLast 30 daysRefreshExport

25 Jul – 23 Aug · 30 days

Billed
41,812,904
Cache reads
2,012,517,338
Turns
10,211
Projects
5
Models
3
Busiest day
12 Aug · 2.9M

Spend per day 26 active

DayWeekMonth

Billed tokens per local day. A mark under a bar is a turn Claude refused.

Hour of day

Every half hour of the range, over one week. Darker is heavier.

Year 190 active

‹2026›Share

Billed tokens per local day. Darker is heavier.

Projects 5

Ranked by billed tokens. Pick one to narrow everything above.

ProjectTurnsBilledCache readsShare
acme-web~/code/acme-web4,18218.4M902.6M
44%
billing-api~/code/billing-api2,1409.1M431.7M
22%
mobile-app~/code/mobile-app1,8846.7M318.2M
16%
design-system~/code/design-system1,1024.3M205.9M
10%
docs-site~/code/docs-site9033.3M154.1M
8%

Models 3

Every model that answered in this range.

ModelTurnsBilledCache readsShare
opus-56,20427.6M1.3B
66%
sonnet-53,41112.1M620.4M
29%
haiku-4-55962.1M92.1M
5%

Read at 21:14

Invented data. Swipe the grid and the tables to see the rest of them.
  1. Spend per day, week or month

    A bar per day, quiet days included — or folded into weeks or months for a long range. A mark under a bar is a day Claude refused a turn.

  2. Hour of day, a month folded onto one week

    A month folded onto one week — when your window actually opens.

  3. Your year, day by day

    A calendar year as a grid, shaded against your own busiest days. Step back a year with ‹ ›.

  4. Every project and model, ranked by what it billed

    Ranked by billed tokens, with the full path under each project. Pick one to narrow everything to it.

  5. Export a report

    Any range as a PDF or an .xlsx — daily, weekly or monthly, one project or all. Written in the browser, sent nowhere.

  6. Share your year

    The year grid as an image, with a post for X or LinkedIn ready to paste it into. Nothing is posted for you.

Reuses the limit cards' read, so it costs almost nothing. Nothing polls — click Refresh.Bookmarkable: range, grouping, year and project live in the URL. Ranges reach back a year and a week.

What you get

Everything you need to keep sessions moving

Limits, live status, token usage and history, on one page.

  • New
    Picks up after the limit resets

    A session that stopped on a limit continues by itself once it resets. Off until you turn it on.

  • Both limits, at the top

    Your five-hour and weekly usage, when they reset, and when they run out.

  • A heads-up before you hit one

    A desktop notification when a window is on course to run out. Off until you turn it on.

  • Where the tokens went

    Spend per day, per half hour, per project, and a whole year as a grid. Pick a project to narrow the page.

  • Reports and a year to share

    Export any range as a PDF or .xlsx. Share your year as an image for X or LinkedIn.

  • What the spend was made of

    Oversized sessions, standing context, model mix — only when something is unusual.

  • Active sessions, verified twice

    Checked against the OS, so working means working.

  • Recent sessions, every project

    Title, prompts, model and branch — find the one worth resuming.

  • A panel per session

    Counts, tokens, working time, subagents, and a copyable resume command.

  • The standing cost, itemised

    What fills the window up front — CLAUDE.md, skills, tools, MCP — priced block by block.

  • Open at login

    autostart on adds it to your login items. The page is waiting when you sit down.

  • A menu bar switch and a widget

    On macOS: turn the tracker on and off from the menu bar, and see both limits as rings in a widget.

  • A Claude Code plugin

    /session-tracker:status prints your limits in the session you are in. /session-tracker:open opens the page.

  • Limits in your terminal

    status prints both limits, today's spend and the running sessions. open brings up the page.

  • Token usage you can sort by

    Coloured by context share, so you see what's about to compact.

  • Scriptable output

    --json prints the page's payload. The HTTP API is open too.

  • Fully keyboard driven

    Filter, move, open and close — all from the keyboard.

  • No dependencies, no install scripts

    Nothing to install or configure. Works the same on npm, pnpm, yarn and bun.

  • Local by construction

    Loopback only, never writes to your Claude directory. Two outbound calls, both off with --offline.

Quickstart

Run it with any package manager

No install needed. Or use Homebrew to keep it on your PATH.

npx claude-code-session-tracker@latest
  1. Run it

    No install step. It starts a local server and opens your browser.

  2. Open the printed address

    Served at http://127.0.0.1:3099.

  3. Watch your sessions

    Refreshes every 2 seconds. Click a row for details.

Start at login

Open your dashboard every time you log in

One command adds it to your login items. Another takes it out.

brew install meyusufdemirci/tap/claude-code-session-tracker
claude-code-session-tracker autostart on

Added as a Login Item, listed in System Settings → General → Login Items.

To turn it off:

claude-code-session-tracker autostart off
  1. Install it once

    A login item needs a copy that stays on disk, so npx won't do here.

  2. Turn it on

    One command, no admin rights. It starts the tracker right away, too.

  3. Log in

    The dashboard opens at http://127.0.0.1:3099 every time.

Inside Claude Code

One slash command away, in the session you are in

A Claude Code plugin: /session-tracker:status prints your limits and running sessions, /session-tracker:open opens the page.

Add the repository as a marketplace, then install it:

/plugin marketplace add meyusufdemirci/claude-code-session-tracker
/plugin install session-tracker@claude-code-session-tracker
CommandWhat it does
/session-tracker:statusPrints both limits and when they reset, what today has billed, and the sessions that are running
/session-tracker:openOpens the page in your browser, starting the tracker first if it is not running
  Claude Code Session Tracker 0.11.0

  5-hour limit  12% used, resets in 3h
  Weekly limit  12% used, resets in 4d 9h
  Today         3.9M tokens in 637 turns

  Running       2 sessions
    busy     my-app      Add the export dialog
    waiting  my-api      Fix the flaky login test (input needed)

  Dashboard     http://127.0.0.1:3099
What /session-tracker:status prints. Invented data.
  1. Ask, and Claude checks

    Ask how much of the weekly limit is left and Claude runs /session-tracker:status by itself. /session-tracker:open only runs when you type it.

  2. Status starts nothing

    A running tracker is asked. When none is, the same numbers are read straight from your Claude directory.

  3. No code of its own

    Each command, and the auto continue hook, runs the CLI — the copy on your PATH, otherwise npx.

  4. The same two in any terminal

    status and open are ordinary commands, so they work outside Claude Code too.

Command line

Options

Every flag, command and keyboard shortcut.

Flag or commandDescriptionDefault
-p, --port <number>Port to listen on, stepping forward up to 20 times if taken3099
--host <address>Address to bind. Anything but loopback drops the guard, and the CLI says so127.0.0.1
--no-openDo not open a browser—
--jsonPrint the session list as JSON and exit—
-n, --limit <number>How many sessions to list. Running sessions always show50
--claude-dir <path>Override the Claude data directory~/.claude
--offlineNever ask Anthropic's server for the usage limits, or npm for a newer version; the cards fall back to Claude Code's cached readout or an estimate—
autostart onStart at login and open the page, on macOS and Windows. Starts it now, too—
autostart offStop starting at login—
autostart statusSay whether it starts at login—
auto-continue onContinue sessions that stopped on a usage limit once it resets. Needs the Claude Code plugin—
auto-continue offLeave them stopped—
auto-continue statusSay whether it is on, and which sessions are waiting—
statusPrint both limits, what today has billed and the running sessions, from a running tracker or straight from disk—
openOpen the page, starting the tracker in the background first if it is not running—
menubar installDownload the macOS menu bar app and widget for this version, install and open them. Run again to update—
menubar install --with-trackerThe same, and install the tracker itself first when this copy came from npx or another one-off runner—
menubar uninstallQuit the app and remove it—
menubar statusSay whether the app is installed, and whether it is the tracker's version—
-h, --helpShow usage—
-v, --versionShow the version—

On the page

  • /Jump to the filter
  • ↑↓Move between sessions, across both tables
  • HomeEndFirst and last session
  • ↵Open the selected session
  • EscClose the panel, or clear the filter

Scripting

An HTTP API, and JSON on stdout

Anything the page does, you can do with curl.

MethodRoute
GET/api/sessions?limit=N

The session list. `limit` matches --limit, and running sessions are always included.

GET/api/sessions?since=&until=

The same list, narrowed by last-written time. Epoch ms; `since` inclusive, `until` exclusive.

GET/api/sessions?sort=

`recent` (default), `tokens-desc`, or `tokens-asc`. Ranks across the whole window, not just the page.

GET/api/sessions/:id

One session with counts, tokens, models, activeMs, awaySummary, and notes.

GET/api/limits

Both limits, as `session` (five hours) and `weekly` (seven days). Each carries the window in progress, Anthropic's percentage as `reported`, the heaviest closed window, and `lastLimited`.

GET/api/usage/history?since=&until=&project=&perProject=

A sparse half-hour series, plus every project and model in the range ranked by billed tokens. Defaults to 30 days; spans over a year and a week (371 days) are narrowed, and `range` in the reply is what was read. `perProject=1` adds each project's own series.

GET/api/usage/advice

The findings behind the `Where it goes` panel as measurements, not sentences. Same params as the history route; defaults to 7 days.

GET/api/update

`current` and `latest` from npm, whether an update is `available`, how it was installed as `method`, the `command` that updates it, and `canInstall` with the `install` progress.

POST/api/update/install

Updates to `latest` with the package manager that installed it, restarts on the same port, and updates the menu bar app. Answers 202; `GET /api/update` follows it. Requires a loopback Origin.

GET/api/auto-continue

Whether auto continue is `enabled`, the `plugin`'s state (`ready`, `missing`, `outdated` or `disabled`), the sessions `pending` a reset with `continueAt`, and the latest `continued` ones.

POST/api/auto-continue

Turns it on or off: `{"enabled": true}`. Answers with the same body as the GET. Requires a loopback Origin.

GET/api/health

Status, version, the Node it runs on, the resolved Claude directory, and per-source status.

POST/api/sessions/:id/reveal

Shows that transcript in your file manager. Requires a loopback Origin.

--json prints the same payload the page uses, then exits.

npx claude-code-session-tracker@latest --json | jq '.sessions[] | .project.name'
{
  "sessions": [
    {
      "id": "279ed6ae-49fd-4234-a74e-145f5535341c",
      "source": "claude-code",
      "status": "busy",              // busy · waiting · idle · ended
      "project": { "name": "…", "path": "…", "gitBranch": "main" },
      "title": "Disable dependabot", // Claude's own title, when it wrote one
      "firstPrompt": "…",
      "lastPrompt": "…",
      "model": "claude-sonnet-5",
      "version": "2.1.235",
      "startedAt": 1787142489923,
      "lastActiveAt": 1787142700231,
      "transcriptPath": "…/279ed6ae….jsonl",
      "sizeBytes": 136133,
      "live": { "pid": 4129, "kind": "interactive", "entrypoint": "cli" }
    }
  ],
  "total": 794,
  "generatedAt": 1787142701002
}

Privacy

Your transcripts never leave this machine

Read-only, loopback-only, and no telemetry.

  • Never writes to your Claude directory

    It only reads what Claude Code already wrote.

  • Loopback only

    Binds to 127.0.0.1 and rejects other hosts, so no website can reach it.

  • Two outbound calls, and --offline

    Claude Code's usage endpoint, and the npm registry for the newest version number. No telemetry, no analytics. Your package manager runs only when you click Update. The macOS app is downloaded only when you ask for it.

  • One thing that acts, and only when asked

    Auto continue, once you turn it on, wakes a session that stopped on a limit. Its switch and the waiting list live in the tracker's own folder.

  • No dependencies, no install scripts

    Nothing third-party runs on your machine.

What it reads

PathUsed for
~/.claude/sessions/<pid>.jsonRunning sessions and their live status
<session cwd>/.git/HEADThe branch a running session is on
~/.claude/projects/**/*.jsonlSession history — titles, prompts, models, branch
~/.claude/projects/*/*/subagents/agent-*.jsonlSubagent turns, for the limit windows they bill to
~/.claude.jsonThe usage readout Claude Code caches — how full each limit is, and when it resets
Keychain · ~/.claude/.credentials.jsonThe token Claude Code is signed in with, to ask for the same readout /usage shows. Skipped with --offline

FAQ

Questions, and the honest answers

Who made this

Yusuf Demirci

Yusuf Demirci builds developer tools at Nefarius Apps, and wrote claude-code-session-tracker after losing track of one too many Claude Code sessions.

One command. No more guessing which session needs you.

Node 20 or newer · macOS, Linux, and Windows. MIT licensed.

npx claude-code-session-tracker@latest