Skip to main content
MCP server CX Codex

Sipcode — Claude Code MCP server: context hygiene and token stats

Watches Claude's context window, catches duplicate file reads, and shows where your tokens went.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add sipcode -- npx -y sipcode
Open on GitHub

What Sipcode does

Sipcode is a local CLI that also runs as an MCP server. It sits between you and Claude, tracks how full the context window gets, and flags a session that starts bloating. Duplicate reads of the same file get caught before they reach the model.

Most of the work happens in the terminal. sipcode drift compares the current session against your usual pattern, sipcode proxy --stats breaks down what the rewriter stripped out, and sipcode today plus sipcode forecast cover spend and a month-end projection. There is also sipcode benchmark, which runs a locked 20-task corpus for a reproducible savings figure. Those transcripts are scripted pairs, not recorded live sessions, so treat the number as a model of the mechanisms rather than an actual bill.

No network calls happen during normal use, so your data stays on the machine. For Codex the server reads session logs under ~/.codex/sessions and ~/.codex/archived_sessions (or wherever CODEX_HOME points) — spend analytics and usage limits only, it does not change what Codex does. Wiring up the MCP server by hand needs Node.js, since the commands launch npx -y sipcode.

What it helps with

  • spot a context window filling up mid-session
  • stop the same file being read twice
  • see token spend for the day
  • project month-end usage
  • check what Codex sessions consumed

Example prompts for the agent

  • Show me the rewriter stats for this session: sipcode proxy --stats
  • Check the latest session for context drift
  • What did I spend today, and what's the month-end forecast?

How to install Sipcode

Platform CLI

claude mcp add sipcode -- npx -y sipcode

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about Sipcode

How do I install Sipcode in Claude Code?

Run claude mcp add sipcode -- npx -y sipcode. The full CLI is installed separately with npm i -g sipcode followed by sipcode init.

What does Sipcode do?

It monitors Claude's context window, removes duplicate file reads and similar waste before they hit the model, and reports token spend.

Does Sipcode change how Codex behaves?

No. For Codex it only reads session logs to report spend and usage limits; Codex itself runs unchanged.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor