# XMemo MCP server

> Provides persistent, governed long-term memory and session continuity for AI agents across different tools and sessions.

- Repository: https://github.com/yonro/memory-os-cli
- Page: https://hostedmcp.org/servers/yonro/memory-os-cli
- Transport: stdio, remote
- Stars: 13
- License: MIT
- Latest version: 0.4.346

## Install

### Claude Code

```sh
claude mcp add --env XMEMO_KEY=<YOUR_XMEMO_KEY> memory-os-cli -- npx -y @xmemo/client
```

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

```json
{
  "mcpServers": {
    "memory-os-cli": {
      "command": "npx",
      "args": [
        "-y",
        "@xmemo/client"
      ],
      "env": {
        "XMEMO_KEY": "<YOUR_XMEMO_KEY>"
      }
    }
  }
}
```

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

```json
{
  "servers": {
    "memory-os-cli": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@xmemo/client"
      ],
      "env": {
        "XMEMO_KEY": "<YOUR_XMEMO_KEY>"
      }
    }
  }
}
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "memory-os-cli": {
      "command": "npx",
      "args": [
        "-y",
        "@xmemo/client"
      ],
      "env": {
        "XMEMO_KEY": "<YOUR_XMEMO_KEY>"
      }
    }
  }
}
```

### Codex (`~/.codex/config.toml`)

```toml
[mcp_servers.memory-os-cli]
command = "npx"
args = ["-y", "@xmemo/client"]

[mcp_servers.memory-os-cli.env]
XMEMO_KEY = "<YOUR_XMEMO_KEY>"
```

### Gemini CLI (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "memory-os-cli": {
      "command": "npx",
      "args": [
        "-y",
        "@xmemo/client"
      ],
      "env": {
        "XMEMO_KEY": "<YOUR_XMEMO_KEY>"
      }
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `XMEMO_KEY` | no | yes | Bearer token issued by XMemo for the stdio proxy. Optional for discovery; required for tool execution. |
| `XMEMO_URL` | no | no | Optional XMemo service base URL. Defaults to https://xmemo.dev. |

## FAQ

### What is XMemo?

XMemo is a user-owned Memory OS for AI agents that provides persistent memory, project context, and session continuity.

### How can I start using XMemo?

You can perform a guided onboarding by installing the client via npm and running the init command.

### Does XMemo support different connection modes?

Yes, it supports hosted Streamable HTTP MCP and local stdio servers for modern editors and agent runtimes.
