# Pharaoh

Pharaoh — an MCP server for Claude Code connects agents to an architectural knowledge graph. The server maps dependencies and computes change impact before modifying files.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 2 repo stars
- Author: Pharaoh-so
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/Pharaoh-so/pharaoh-mcp
- Updated: 2026-11-14
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/mcp/pharaoh

## What it does

The proxy links an agent to a structural graph of your project via stdio and SSE. Instead of scanning files individually, the assistant queries module boundaries, finds duplicate logic with `search_functions`, and assesses ripple effects using `get_blast_radius`. A single `pharaoh_recon` call returns map data, context, and impact scope at once.

Operation requires Node.js 18 or newer and an active account on `pharaoh.so`. Pharaoh indexes code directly through its GitHub App, so the local proxy never transmits source file contents. Credentials persist in `~/.pharaoh/credentials.json` with `0600` permissions and expire after 7 days.

## Requirements
- Needs: Node.js (commands run via npx)
- Remote server: `https://mcp.pharaoh.so/mcp`

## Install

### Claude Code (native platform)

1. **Platform CLI: remote server**
```bash
claude mcp add --transport http pharaoh https://mcp.pharaoh.so/mcp
```

2. **Platform CLI**
```bash
claude mcp add pharaoh -- npx -y @pharaoh-so/mcp
```

### Codex

1. **Platform CLI: remote server**
```bash
codex mcp add pharaoh --url https://mcp.pharaoh.so/mcp
```

2. **Platform CLI**
```bash
codex mcp add pharaoh -- npx -y @pharaoh-so/mcp
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "pharaoh": {
            "url": "https://mcp.pharaoh.so/mcp"
        }
    }
}
```
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "pharaoh": {
            "command": "npx",
            "args": [
                "-y",
                "@pharaoh-so/mcp"
            ]
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "pharaoh": {
            "type": "http",
            "url": "https://mcp.pharaoh.so/mcp"
        }
    }
}
```
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "pharaoh": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@pharaoh-so/mcp"
            ]
        }
    }
}
```

### Gemini CLI

1. **Platform CLI: remote server**
```bash
gemini mcp add -t http pharaoh https://mcp.pharaoh.so/mcp
```

2. **Platform CLI**
```bash
gemini mcp add pharaoh npx -y @pharaoh-so/mcp
```

## When to use it
- calculate breaking impact of editing a function with get_blast_radius
- locate existing implementations before writing duplicate code
- inspect module relationship maps via get_codebase_map
- gather full structural context prior to refactoring

## Example prompts
- Run pharaoh_recon to see what breaks if we modify authenticateUser
- Check search_functions for existing JWT validation helpers
- Map the payment module dependencies before refactoring

## Similar
- [explore-codebase](https://affpapa.org/en/nevibecode/skills/explore-codebase.md) — skill · 1200 installs
- [code-migrate](https://affpapa.org/en/nevibecode/commands/code-migrate.md) — command · ★ 42780 repo stars
- [documenting-legacy-codebases](https://affpapa.org/en/nevibecode/skills/documenting-legacy-codebases.md) — skill · 26600 installs
- [repo-skillopt](https://affpapa.org/en/nevibecode/skills/repo-skillopt.md) — skill · 598 installs
- [w-council](https://affpapa.org/en/nevibecode/skills/w-council.md) — skill · 647 installs
- [explore](https://affpapa.org/en/nevibecode/skills/explore.md) — skill · 581 installs

---
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
