# XERJ

> XERJ is an open-source MCP server for knowledge and memory. Local search engine for AI agents with cited answers over your code and docs. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Linux, macOS, self-hosted, API
- **Website:** https://xerj.org
- **Repository:** https://github.com/xerj-org/xerj
- **GitHub stars:** 19,160
- **License:** Apache-2.0
- **MCP Registry name:** io.github.xerj-org/xerj
- **Categories:** knowledge and memory, developer tools
- **Listing updated:** 2026-11-14

## About

XERJ is a local search engine built for AI agents, shipped as a single Rust binary. It combines search, vectors, facts, memory and an Elasticsearch-compatible API, and runs offline on a CPU.

Its XERJ Query-1 model turns a question into a short program that the engine runs over stored facts, returning the answer with evidence. With no supporting fact it answers UNKNOWN. The MCP server connects an agent to a running XERJ node, and can index open-source repos so agents read real definitions.

It suits developers whose agents need code and docs search, and teams that keep data inside their network.

## Features

- **Single binary:** Search, vectors, facts and memory in one Rust program.
- **Evidence-backed answers:** Answers come with the program and evidence used.
- **Runs locally:** Works offline on a CPU, on a laptop or server.
- **Elasticsearch-compatible API:** Exposes an API compatible with Elasticsearch.
- **Reference coding:** Index open-source repos so agents consult real definitions.
- **MCP integration:** Stdio MCP server connects to a running node.

## Good for

- Search local code and docs from an agent
- Give an agent persistent memory notes
- Look up real API definitions
- Answer questions with checkable evidence
- Keep search inside a private network

## Install

### Claude Code (Terminal)

```sh
claude mcp add xerj --env XERJ_AUTH='<XERJ_AUTH>' -- npx -y https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "xerj": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb"
      ],
      "env": {
        "XERJ_AUTH": "<XERJ_AUTH>"
      }
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "xerj": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb"
      ],
      "env": {
        "XERJ_AUTH": "<XERJ_AUTH>"
      }
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "xerj": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb"
      ],
      "env": {
        "XERJ_AUTH": "<XERJ_AUTH>"
      }
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "xerj": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb"
      ],
      "env": {
        "XERJ_AUTH": "<XERJ_AUTH>"
      }
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "xerj": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb"
      ],
      "env": {
        "XERJ_AUTH": "<XERJ_AUTH>"
      }
    }
  }
}
```

## FAQ

### Does it need a running server?

Yes, the MCP server connects to a XERJ node at XERJ_URL, default http://localhost:9200.

### What license applies?

The engine source is Apache-2.0.

### Does it work offline?

Yes, the site says it runs offline on a CPU.

### What does it say without evidence?

It returns UNKNOWN.

### Is XERJ free?

Yes. XERJ is open source, so you can use and self-host it for free.

### How do I add XERJ to Claude Code?

Run this command in your terminal: claude mcp add xerj --env XERJ_AUTH='<XERJ_AUTH>' -- npx -y https://github.com/xerj-org/xerj/releases/download/mcpb-v1.0.0-rc.99/xerj-mcp-1.0.0-rc.99.mcpb

### What are the best alternatives to XERJ?

The closest alternatives to XERJ are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and Ouroboros.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.
- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [Nautilus Compass Memory](https://ai-powered.com/mcp/nautilus-compass-memory): Nautilus Compass Memory is an open-source MCP server for knowledge and memory.
- [Concord MCP](https://ai-powered.com/mcp/concord-mcp): Concord MCP is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/xerj
