STOP PAYING
FOR NOISE
claudectx surgically removes redundant tokens from every Claude Code request — cutting costs by up to 80% while preserving 100% of accuracy.
13 commands · Zero config changes · Works in 60 seconds
npm install -g claudectx
Or try without installing: npx claudectx analyze
The Root Cause
Where Your Tokens Actually Go
A typical Claude Code session costs $2–$15. Most of it is wasted on context you never needed.
| Component | Typical Tokens | % of Total | Fixable? |
|---|---|---|---|
| Claude Code system prompt | 4,200 | 14% | No |
| Tool definitions (built-in) | 2,100 | 7% | No |
| MCP tool schemas | 1,980 | 7% | Partially |
| CLAUDE.md BIGGEST WIN | 6,800–14,000 | 22–46% | YES |
| MEMORY.md / memory files | 3,300 | 11% | YES |
| Conversation history (grows) | 2,000–40,000 | 7–57% | YES |
Teal rows = fixable with claudectx
Bloated CLAUDE.md injected on every single request — even for a one-line change.
claudectx optimize --claudemd
No .claudeignore means Claude reads node_modules, lock files, and build artifacts on every search.
claudectx optimize --ignorefile
Full file reads for small questions. claudectx mcp lets Claude read one function instead of the whole file.
claudectx mcp --install
Terminal Interface
Real Commands. Real Output.
Watch claudectx analyse your project, optimize it, and report the savings.
Token Efficiency
Before vs After
Same project. Same Claude. One command changed everything.
Core Capabilities
Six Ways to Kill Token Waste
Intelligent
CLAUDE.md
Optimization
Parses your CLAUDE.md by ## sections, keeps core rules inline (<2K tokens), moves reference docs to demand-loaded @file references. Up to 12,200 tokens saved per request.
claudectx optimize --claudemd
Symbol-Level MCP Server
Read one function instead of a whole file. smart_read, search_symbols, index_project — Claude gets exactly what it needs, nothing more.
claudectx mcp --installLive Token Dashboard
Real-time terminal UI: burn rate, cache hit rate, most-read files — while Claude is coding.
claudectx watch
Cross-Session Memory
8,000-token session compressed to ~180 tokens in MEMORY.md. 97.8% reduction. Key context survives across sessions.
claudectx compress
Prompt Cache Warmup
Pre-warm the Anthropic cache before you start coding. First request = cache hit, not a cold miss paying 10×.
claudectx warmup
Multi-Assistant Convert
Export your CLAUDE.md to Cursor, Copilot, or Windsurf in one command. Same instructions, every AI tool.
claudectx convert --to cursor
Quick Start
Up and Running in 60 Seconds
Three commands. No config files. No accounts required.
Install globally
Or skip the install entirely and try it right now.
npm install -g claudectx
npx claudectx analyze # no install needed
Analyse your project
See token breakdown, cost per request, and exactly what to fix.
claudectx analyze
Auto-fix everything
All changes are backed up automatically before anything is modified.
claudectx optimize --apply
claudectx revert
--dry-run
Requires Node.js 18+ · Also available via Homebrew and pip · 100% local — no data leaves your machine
Command Reference
13 Commands. One Purpose.
Everything you need to control, compress, and understand your context window.
analyze
CORE
See exactly where your tokens go. Cost per request, waste patterns, and optimization opportunities — all in one table.
optimize
CORE
Auto-fix token waste. CLAUDE.md splitter, .claudeignore generator, cache advisor, hooks installer. One command, everything fixed.
watch
LIVE
Real-time terminal dashboard showing token burn rate, cache hit rate, and most-read files while Claude is working.
mcp
SERVER
Smart MCP server: Claude reads one function instead of a whole file. Up to 97% fewer tokens per read via smart_read, search_symbols.
compress
MEMORY
Compress the full session JSONL into a compact MEMORY.md entry. A typical 8,000-token session → ~180 tokens. 97.8% reduction.
report
ANALYTICS
7/30-day usage analytics: sessions, requests, input tokens, cache hit rate, cost estimate, and top files by read count.
For Engineering Leads
Know Where the Budget Goes
claudectx teams gives per-developer cost attribution without sharing session content or prompts.
Each developer runs this locally on their own machine. Generates a lightweight JSON file — no session content, just aggregated token counts.
→ ~/.claudectx/team-export-{date}.json
Collect the JSON files in a shared directory. Aggregate them to see per-developer spend, cache hit rate, avg request size, and top shared waste files.
--dir ./reports/
Use --anonymize to replace identities with "Dev 1, Dev 2..." before sharing. No prompts, no conversation history — only token counts.
--anonymize