optimAIzr for VS Code
Claude Code’s context, cache countdown and 5-hour window in the status bar. A heads-up 5 minutes before a cache expires, guard in one click, and the fixes biggest money first. Free, and everything stays on your machine.
What it shows
The Claude Code conversation in the folder you have open: 143K of context, 54 minutes 51 seconds left on its cache, 56% of the 5-hour window used. Yellow in the cache's last five minutes, red past 90% of the window.
“5 min left on the cache for "Build the VS Code extension". Reply before then to skip a $1.14 rewrite.” About 5 minutes before a long conversation's cache expires, when coming back after it would cost $0.50 or more.
About 1.1x the work per 5-hour window and per week, on mine. $685/mo of work at API prices on Claude Pro, 34x what the plan costs. Yours show up the moment the extension opens.
51 returns to an expired cache wrote 8.9M tokens again in 30 days, $56.02/mo. Guard holds the next message to an expired cache once and says what it would cost; send it again and it goes through. It also catches a big file read and a retry loop.
Biggest money first, each with what happened, why it costs and what to do. Habits get an I did this button, so results can measure whether it worked.
One click to compact Claude Code at 200K, one to undo it, and the rest of your settings stay as they were. On mine, 5% to 24% less per prompt, measured Oct 19, 2026.
A desktop notification when a turn of 45 seconds or more finishes while VS Code is in the background. macOS and Linux.
Where the share comes from, the biggest single win and every fix opened up, in an editor tab.
The extension on the maker’s machine, Oct 29, 2026, over the last 30 days. Compaction at 200K was already applied, so it is left out of what is still to save, and the share is lower than a first run shows. Yours come from your own usage.
Claude Code, and the rest for savings
The status bar, the heads-up, guard and the done alert watch Claude Code. The savings also read Codex and opencode, as the CLI does. In a terminal, optimaizr live watches all three.
Private by design
It reads the logs Claude Code already keeps in ~/.claude, and Codex and opencode for the savings, and works everything out on your machine. No account, no upload, no telemetry. Token counts and the titles Claude Code gives conversations, never your prompts or Claude’s answers.
Everything in the sidebar works on its own. Turning guard on uses the free optimaizr CLI, and the extension offers to install it with npm i -g optimaizr.
What it needs
- VS Code 1.90 or newer
- Claude Code, with some history in
~/.claude - For guard only: Node.js 20 or newer