# parecode

An MCP server for token-aware code search and atomic edits across multiple files. It helps agents inspect large repositories with bounded context.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 5
- Author: BasilSkyWalk
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/BasilSkyWalk/parecode
- Updated: 2026-09-14
- HTML: https://affpapa.org/en/nevibecode/mcp/parecode

## What it does

parecode exposes `ParecodeSearch`, `ParecodeExpand`, and `ParecodeEdit` to an MCP client. Search runs through `ripgrep`, returns matches with nearby lines, and reports estimated token use. When a result is clipped, the agent can request a wider range instead of loading the whole file.

\`ParecodeEdit` batches changes across files, checks file stats before and after an edit, and writes same-directory renames atomically. Multiple related patterns can be searched in parallel. The server also keeps a local JSONL session log through `parecode stats`; runtime network calls are not used.

Node.js 20 or newer and `ripgrep` on `PATH` are required. parecode shells out to the system binary, so searches fail when `ripgrep` is missing from `PATH`.

## Requirements
- Needs: Node.js (commands run via npx)

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add parecode -- npx -y parecode
```

### Codex

**Platform CLI**
```bash
codex mcp add parecode -- npx -y parecode
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "parecode": {
            "command": "npx",
            "args": [
                "-y",
                "parecode"
            ]
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "parecode": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "parecode"
            ]
        }
    }
}
```

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add parecode npx -y parecode
```

## When to use it
- trace every use of a symbol with nearby context
- widen a located code range without reading the whole file
- apply one atomic change across several files
- search related patterns in a single request
- inspect estimated token savings from local session logs

## Example prompts
- Use `ParecodeSearch` to find every call to `createUser` and include nearby context.
- Use `ParecodeExpand` on `src/users.ts` for the range around lines 40–65.
- Replace `oldApi` with `newApi` across all matching files using `ParecodeEdit`.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 392262
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33989
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81163
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119231
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47577
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43902

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
