# Memory v2

> Memory v2 is an open-source MCP server for knowledge and memory. Local SQLite memory for AI agents, with projects, branches and durable facts over MCP. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** Windows, Linux, Web, API, CLI, Self-hosted, Chrome extension, Firefox extension
- **Repository:** https://github.com/donparalon85/memory-v.2-alpha
- **MCP Registry name:** io.github.DonParalon85/memory-v2
- **Categories:** [knowledge and memory](https://ai-powered.com/categories/knowledge-and-memory), [agent memory](https://ai-powered.com/categories/agent-memory)
- **Listing updated:** 2026-11-28

## About

Memory v2 keeps long-running agent work in a single SQLite file on your own machine. Projects hold many conversation branches, and durable facts such as decisions, constraints and preferences can be stored, superseded or retired over time.

Agents reach it through a seven-tool MCP server that talks to the local HTTP API rather than opening the database directly. Full-text search, with Russian morphology, covers both stored memories and archived messages, and archiving the same branch twice only appends new messages.

The project suits developers and power users who want agent context they can copy, back up and inspect without an account or a network dependency. It is an alpha release, so the author recommends backing up the database before relying on it.

## Features

- **Projects and branches:** Groups many conversation branches under one project with shared search and context.
- **Durable memories:** Stores facts, decisions, constraints and preferences with importance, confidence and supersede links.
- **Message provenance:** Keeps source fingerprints and revisions, and soft-deletes messages so they remain recoverable.
- **Full-text search:** Searches memories and messages using SQLite FTS5 with Russian morphology support.
- **Idempotent archive:** Re-sending a branch appends only new messages and skips duplicates.
- **Local-first storage:** Data lives in one SQLite file, listens on loopback by default and needs no cloud account.

## Good for

- Give a coding agent persistent project context across sessions and model switches
- Archive long chat branches so they can be restored later with one request
- Store project decisions and constraints that an MCP client can query on demand
- Keep agent memory offline on a personal or work machine

## Install

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

```sh
claude mcp add memory-v2 --env MEMORY_API_TOKEN='<MEMORY_API_TOKEN>' -- uvx memory-v2-mcp
```

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-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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-v2 --env MEMORY_API_TOKEN='<MEMORY_API_TOKEN>' -- uvx memory-v2-mcp
```

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

```toml
[mcp_servers.memory-v2]
command = "uvx"
args = ["memory-v2-mcp"]
env = { MEMORY_API_TOKEN = "<MEMORY_API_TOKEN>" }
```

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

Or run: gemini mcp add -s user -e MEMORY_API_TOKEN='<MEMORY_API_TOKEN>' memory-v2 uvx -- memory-v2-mcp

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

The AI Assistant docs only show command and args. If the env block is ignored, use Junie for this server.

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "memory-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

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-v2": {
      "command": "uvx",
      "args": [
        "memory-v2-mcp"
      ],
      "env": {
        "MEMORY_API_TOKEN": "<MEMORY_API_TOKEN>"
      }
    }
  }
}
```

## Tools

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

- `memory_health`: Check API availability
- `memory_list_projects` (name suggests: reads): List projects
- `memory_project_context`: Restore a project and its branches
- `memory_search` (name suggests: reads): Search memories and messages
- `memory_archive_conversation` (name suggests: changes): Archive a branch idempotently
- `memory_upsert`: Store a fact, decision, constraint or preference
- `memory_deprecate`: Retire an old memory, optionally with a replacement

## FAQ

### Does Memory v2 need an account or internet connection?

No account is required and the installers work offline. The API listens on loopback by default.

### How do MCP clients connect to Memory v2?

The MCP server runs over stdio and is published on PyPI as memory-v2-mcp, so it can be started with uvx.

### Which MCP tools are available?

Seven tools: health check, list projects, project context, search, archive conversation, upsert memory and deprecate memory.

### Where is the data stored?

In a plain SQLite file, by default at data/memory_v2.db, which you can copy and inspect.

### Is Memory v2 free?

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

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

Run this command in your terminal: claude mcp add memory-v2 --env MEMORY_API_TOKEN='<MEMORY_API_TOKEN>' -- uvx memory-v2-mcp

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

The closest alternatives to Memory v2 are MCP Memory, Agent Memory Os, MCP Light Memory, Memkeeper and Mnemon MCP.

## Where this comes from

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

## Alternatives

- [MCP Memory](https://ai-powered.com/mcp/mcp-memory): MCP Memory is an open-source MCP server for knowledge and memory.
- [Agent Memory Os](https://ai-powered.com/mcp/agent-memory-os): Agent Memory Os is an open-source MCP server for knowledge and memory.
- [MCP Light Memory](https://ai-powered.com/mcp/mcp-light-memory): MCP Light Memory is an open-source MCP server for knowledge and memory.
- [Memkeeper](https://ai-powered.com/mcp/memkeeper): Memkeeper is an open-source MCP server for knowledge and memory.
- [Mnemon MCP](https://ai-powered.com/mcp/mnemon-mcp): Mnemon MCP is an open-source MCP server for knowledge and memory.
- [Memoire](https://ai-powered.com/mcp/memoire-2): Memoire is an open-source MCP server for knowledge and memory.
- [Memento](https://ai-powered.com/mcp/memento): Memento is an open-source MCP server for knowledge and memory.

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