# Memoria

> Memoria is an open-source MCP server for knowledge and memory. Local-first shared memory that carries decisions and fixes between AI coding tools. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, macOS, Windows, Linux, API, Self-hosted, VS Code
- **Repository:** https://github.com/xinzzu/memoria
- **MCP Registry name:** io.github.xinzzu/memoria
- **Categories:** [knowledge and memory](https://ai-powered.com/categories/knowledge-and-memory)
- **Listing updated:** 2026-11-19

## About

The README says Memoria watches sessions from tools such as Claude Code, Codex, Gemini CLI, Cursor and VS Code, then extracts facts, decisions, open tasks and fixed errors into a single SQLite store on the user's machine. When a session goes idle or a usage limit is reported, a resume engine writes a marked block into AGENTS.md, CLAUDE.md or GEMINI.md so the next tool starts with the same context.

Agents reach the store through an MCP server offered over stdio or a local HTTP bridge at port 48210. Tools include recall, remember, update_memory, forget, file_context and build_context. Extraction works without any model using built-in heuristics, and can be upgraded to a local Ollama model or an OpenAI-compatible endpoint that the user opts into.

It suits developers who switch between several AI coding assistants and want decisions and unfinished work to follow them without re-explaining. Optional end-to-end encrypted sync between a user's own machines is also described.

## Features

- **Cross-tool session capture:** Reads session data from nine AI coding tools, including Claude Code, Codex, Cursor and Windsurf, in near real time.
- **Automatic resume block:** Injects open tasks, locked decisions and dirty git files into context files when a session goes idle or hits a limit.
- **Pre-limit work snapshot:** Saves files touched, commands run and git state when an AI tool reports a usage limit.
- **Local MCP memory tools:** Exposes recall, remember, forget and related tools to MCP clients over stdio or HTTP on localhost.
- **Works without a model:** Heuristic extraction runs by default, with optional Ollama or OpenAI-compatible engines.
- **Encrypted device sync:** Syncs memory between a user's own machines through end-to-end encrypted bundles, excluding embeddings and secrets.

## Good for

- Continue a coding task in a different AI tool after hitting a usage limit
- Recall past architectural decisions before editing a project
- Check previous fixes for a file before changing it
- Share project conventions with a team through a committed brain file

## Install

### Claude Code (Terminal)

```sh
claude mcp add memoria -- npx -y @xinzzu/memoria
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "memoria": {
      "command": "npx",
      "args": [
        "-y",
        "@xinzzu/memoria"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "memoria": {
      "command": "npx",
      "args": [
        "-y",
        "@xinzzu/memoria"
      ]
    }
  }
}
```

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

```json
{
  "servers": {
    "memoria": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@xinzzu/memoria"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "memoria": {
      "command": "npx",
      "args": [
        "-y",
        "@xinzzu/memoria"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "memoria": {
      "command": "npx",
      "args": [
        "-y",
        "@xinzzu/memoria"
      ]
    }
  }
}
```

## Tools

- `recall`: Project-scoped memory recall within a token budget.
- `remember`: Stores a memory with ADD, UPDATE or NOOP decisions.
- `update_memory`: Edits an existing memory.
- `forget`: Removes a memory.
- `related`: Finds memories related to a given one.
- `project_context`: Returns a compact index of project memories.
- `get_memory`: Returns full text for selected memory ids.
- `file_context`: Lists fixed errors, decisions and open tasks mentioning a file.
- `build_context`: Builds one ready-to-paste context block within a character budget.

## FAQ

### Does my data leave my computer?

The README says capture, extraction and search run locally in ~/.memoria. Data leaves the machine only if the user explicitly configures the OpenAI-compatible tier.

### Do I need Ollama?

No. The README says heuristics work with zero models, and Ollama is an optional upgrade that is detected automatically.

### Which MCP tools are included?

The README lists nine tools: recall, remember, update_memory, forget, related, project_context, get_memory, file_context and build_context.

### Is Memoria free?

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

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

Run this command in your terminal: claude mcp add memoria -- npx -y @xinzzu/memoria

### What are the best alternatives to Memoria?

The closest alternatives to Memoria are Memware — Cross-Agent Long-Term Memory, Cross-Agent Memory, Total Agent Memory, memry and Agent Memory 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

- [Memware — Cross-Agent Long-Term Memory](https://ai-powered.com/mcp/memware-cross-agent-long-term-memory): Memware — Cross-Agent Long-Term Memory is a freemium MCP server for knowledge and memory.
- [Cross-Agent Memory](https://ai-powered.com/mcp/cross-agent-memory): Cross-Agent Memory is an open-source MCP server for knowledge and memory.
- [Total Agent Memory](https://ai-powered.com/mcp/total-agent-memory): Total Agent Memory is an open-source MCP server for knowledge and memory.
- [memry](https://ai-powered.com/mcp/memry): memry is an MCP server for developer tools.
- [Agent Memory MCP](https://ai-powered.com/mcp/agent-memory-mcp): Agent Memory MCP is an open-source MCP server for knowledge and memory.
- [Memoria — Deterministic AI Memory & Code Intelligence MCP](https://ai-powered.com/mcp/memoria-deterministic-ai-memory-and-code-intelligence-mcp): Memoria — Deterministic AI Memory & Code Intelligence MCP is a freemium MCP server for knowledge and memory.
- [Compound Memory](https://ai-powered.com/mcp/compound-memory): Compound Memory is an open-source MCP server for knowledge and memory.
- [MCP Memory](https://ai-powered.com/mcp/mcp-memory): MCP Memory is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/memoria-2
