# Memory Fabric

> Memory Fabric is a free MCP server for knowledge and memory. Local Markdown memory for coding assistants, with no vector database or cloud account. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Free
- **Platforms:** CLI, Self-hosted
- **Repository:** https://github.com/elvirafa/agentic-memory
- **MCP Registry name:** io.github.elViRafa/memory-fabric
- **Categories:** [knowledge and memory](https://ai-powered.com/categories/knowledge-and-memory), [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-23

## About

Facts live as one Markdown file each with YAML frontmatter inside a `memory-store/` folder in your repository, so you can read, diff and commit them like any other project file. Summary maps such as architecture and decisions are generated views that a maintenance pass called Dreaming rebuilds, rather than documents anyone edits by hand.

Capture does not depend on the agent remembering to save things. An opt-in post-commit hook records each git commit as episodic memory, and a failure-memory tool folds repeated occurrences of the same error into a single growing record. Memories can cite the file, line or commit they rely on, and a verify command flags citations that have gone stale.

The README says core reads and writes make no network calls, secrets such as API keys are redacted before anything is written, and context is assembled inside a token budget without cutting files mid-document. A custom git merge driver is available so memory on two branches merges the way code does. It needs Python 3.11 or newer.

## Features

- **Git-commit capture:** An optional post-commit hook records every commit as episodic memory without the agent doing anything.
- **Failure memories:** Repeated occurrences of the same error are merged into one growing record instead of many near-duplicates.
- **Citation checking:** Memories can point to files, lines or commits, and a verify command flags citations that no longer hold.
- **Secret redaction:** API keys and credentials are removed before a memory is written to disk.
- **Token-budgeted context:** Context is assembled within a size limit and never slices a file mid-document.
- **Git-aware merging:** An optional merge driver lets memory from two branches merge cleanly.
- **Local quality eval:** A built-in eval scores how useful the stored memories are and compares Dreaming before and after.

## Good for

- Give Claude Code, Cursor and Copilot the same project memory
- Keep architecture decisions in version control next to the code
- Record why an error happened so it is not rediscovered later
- Audit stored notes for stale references after a refactor
- Run an agent memory layer on an offline or locked-down machine

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add memory-fabric -- uvx memory-fabric
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

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

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add memory-fabric -- uvx memory-fabric
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.memory-fabric]
command = "uvx"
args = ["memory-fabric"]
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user memory-fabric uvx -- memory-fabric

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

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

```json
{
  "mcpServers": {
    "memory-fabric": {
      "command": "uvx",
      "args": [
        "memory-fabric"
      ]
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 1 of 1 tool changes data. From the server's own tool labels and tool names; not verified by us.

- `write_failure_memory_tool` (name suggests: changes): Records an error as a failure memory, merging repeats of the same error into one record.

## FAQ

### Does Memory Fabric need a vector database or embeddings?

No. Memory is plain Markdown with YAML frontmatter, and the README states that no vector database, cloud account or embeddings are required.

### Does Memory Fabric send any data off my machine?

The README describes no telemetry, account or phone-home. The only optional network calls are a PyPI version check and an LLM-provider preflight, both of which `--offline` turns off.

### How do I install the MCP server?

Install the PyPI package with the mcp extra (`pipx install "memory-fabric[mcp]"`) or run it once with `uvx --from "memory-fabric[mcp]" memory-fabric-mcp`. Python 3.11 or newer is required.

### Which assistants can use Memory Fabric?

Any MCP-compatible client over stdio; the README names Claude Code, Cursor and GitHub Copilot.

### Is Memory Fabric free?

Yes. Memory Fabric is free to use.

### How do I add Memory Fabric to Claude Code?

Run this command in your terminal: claude mcp add memory-fabric -- uvx memory-fabric

### What are the best alternatives to Memory Fabric?

The closest alternatives to Memory Fabric are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [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): 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.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/memory-fabric
