Cachebro

v1.0.0Coding Agentsstable

File cache with diff tracking for AI coding agents. Drop-in MCP server that cuts token usage by 26%.

cachebromcpai-integration
Share:
188
Stars
0
Downloads
0
Weekly
0/5

What is Cachebro?

Cachebro is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to file cache with diff tracking for ai coding agents. drop-in mcp server that cuts token usage by 26%.

File cache with diff tracking for AI coding agents. Drop-in MCP server that cuts token usage by 26%.

This server falls under the Coding Agents and Developer Tools categories on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • File cache with diff tracking for AI coding agents. Drop-in

Use Cases

Reduce token usage by 26% with intelligent file caching.
Track file changes with diff-based caching for faster iterations.
Accelerate AI coding with drop-in MCP server integration.
glommer

Maintainer

LicenseMIT
Languagetypescript
Versionv1.0.0
UpdatedMay 21, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx cachebro

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Cachebro

Cachebro is a drop-in MCP server for AI coding agents that caches file reads and returns diffs on subsequent reads, reducing token usage by roughly 26% for typical coding sessions. Instead of sending the full content of a file every time the agent reads it, Cachebro returns 'unchanged' or a compact unified diff when only part of the file changed — dramatically cutting the tokens consumed in long editing sessions. It requires zero changes to your existing workflow: just add it to your MCP client config and it transparently intercepts file read calls.

Prerequisites

  • Node.js 18 or newer with npx available
  • Claude Code, Cursor, or another MCP-capable AI coding client
  • A project directory where the agent will be reading and editing files
1

Initialize Cachebro in your project

Run the init command in your project root. It auto-detects Claude Code, Cursor, and OpenCode and writes the MCP configuration for you.

npx cachebro init
2

Or add Cachebro manually to your MCP config

If you prefer manual setup or use a different client, add Cachebro to your claude_desktop_config.json or .claude.json directly.

{
  "mcpServers": {
    "cachebro": {
      "command": "npx",
      "args": ["cachebro", "serve"],
      "env": {
        "CACHEBRO_DIR": ".cachebro"
      }
    }
  }
}
3

Verify the server starts correctly

Start the Cachebro server manually to confirm it runs without errors before connecting through the MCP client.

npx cachebro serve
4

Restart your AI coding client

Restart Claude Code or Cursor so it picks up the Cachebro MCP server. Subsequent file reads made by the agent will go through Cachebro's cache layer automatically.

5

Check token savings

After a coding session, check the cache statistics to see how many tokens were saved.

npx cachebro status

Cachebro Examples

Client configuration

Manual claude_desktop_config.json entry for Cachebro, using the default .cachebro directory for the cache database.

{
  "mcpServers": {
    "cachebro": {
      "command": "npx",
      "args": ["cachebro", "serve"],
      "env": {
        "CACHEBRO_DIR": ".cachebro"
      }
    }
  }
}

Prompts to try

Cachebro works transparently — instruct the agent to use its read_file tool instead of the built-in file reading. These prompts help demonstrate the token savings.

- "Read src/auth.ts using cachebro and tell me what the login function does"
- "Read these five files and summarize the architecture: src/index.ts, src/routes.ts, src/models/user.ts, src/middleware/auth.ts, src/utils/db.ts"
- "Show me the current cachebro cache status and how many tokens we've saved"
- "Clear the cachebro cache so all files are re-read fresh"
- "Read src/auth.ts again — has it changed since you last read it?"

Troubleshooting Cachebro

npx cachebro init does not write the config for my client

The init command auto-detects Claude Code (.claude.json), Cursor (.cursor/mcp.json), and OpenCode. For other clients, add Cachebro manually to your client's MCP configuration file using the JSON shown in the setup step above.

Cache shows 'unchanged' for a file that was actually modified

Cachebro detects changes by comparing file content at read time. If the file was modified outside the current session (e.g., by a build tool), run 'npx cachebro status' and then 'npx cachebro clear' to reset the cache and force a fresh full read on the next access.

CACHEBRO_DIR causes a permission error

The .cachebro directory is created in the current working directory when Cachebro starts. Ensure the MCP server's working directory is set to your project root and that the process has write access to that directory.

Frequently Asked Questions about Cachebro

What is Cachebro?

Cachebro is a Model Context Protocol (MCP) server that file cache with diff tracking for ai coding agents. drop-in mcp server that cuts token usage by 26%. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Cachebro?

Follow the installation instructions on the Cachebro GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Cachebro?

Cachebro works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Cachebro free to use?

Yes, Cachebro is open source and available under the MIT license. You can use it freely in both personal and commercial projects.

Browse More Coding Agents MCP Servers

Explore all coding agents servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "cachebro": { "command": "npx", "args": ["-y", "cachebro"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Cachebro?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides