Mem0 Mcp Selfhosted

data-ai MCP Server

Self-hosted mem0 MCP server for Claude Code. Run a complete memory server against self-hosted Qdrant + Neo4j + Ollama while using Claude as the main LLM.

Install Ready
data-aidata-ai
5 views93 stars38 forksMIT

Why This Matters

Discovered via unknown and last synced 3mo ago.

Install Ready
Source
unknown
Stars
93
Last synced
3mo ago
Install
Instructions detected

Install

1. Install the package

uvx --from git+https://github.com/elvismdev/mem0-mcp-selfhosted.git mem0-mcp-selfhosted

2. Add to claude_desktop_config.json

{
  "mcpServers": {
    "mem0-mcp-selfhosted": {
      "command": "npx",
      "args": [
        "mem0-mcp-selfhosted"
      ]
    }
  }
}

Config file location: ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) / %APPDATA%\Claude\claude_desktop_config.json (Windows)

63
Tools
0
Resources
0
Prompts
Standard I/O
Transport

Available Tools (63)

delete_entities

Cascade-delete an entity and all its memories.

Service

Required

mem0-hook-stop

`hooks:stop_main`

3

`ANTHROPIC_API_KEY` env var

delete_all_memories

Bulk-delete all memories in a scope.

MEM0_GRAPH_LLM_MODEL

_(varies)_

MEM0_EMBED_DIMS

`1024`

MEM0_NEO4J_USER

`neo4j`

Mode

Use Case

Command

Function

4

Disabled

list_entities

List users/agents/runs with memory counts. Uses Qdrant Facet API.

MEM0_PROVIDER

`anthropic`

MEM0_GRAPH_CONTRADICTION_LLM_PROVIDER

`anthropic`

MEM0_NEO4J_PASSWORD

`mem0graph`

sse

Legacy remote clients

Yes

Embedding generation (`bge-m3`) and optionally local LLM

Tool

Description

MEM0_OLLAMA_URL

`http://localhost:11434`

MEM0_OLLAMA_KEEP_ALIVE

`30m`

MEM0_QDRANT_ON_DISK

`false`

Hook

Event

1

`MEM0_ANTHROPIC_TOKEN` env var

update_memory

Replace memory text. Re-embeds and re-indexes in Qdrant.

MEM0_OAT_HEADERS

`auto`

MEM0_GRAPH_LLM_PROVIDER

_(MEM0_PROVIDER)_

MEM0_EMBED_MODEL

`bge-m3`

MEM0_ENABLE_GRAPH

`false`

MEM0_USER_ID

`user`

mem0-hook-context

`hooks:context_main`

2

`~/.claude/.credentials.json`

delete_memory

Delete a single memory by UUID.

MEM0_OAT_REFRESH_THRESHOLD_SECONDS

`1800`

MEM0_GRAPH_LLM_URL

_(cascades)_

MEM0_EMBED_URL

_(cascades)_

MEM0_NEO4J_URL

`bolt://127.0.0.1:7687`

MEM0_LOG_LEVEL

`INFO`

mem0-install-hooks

`hooks:install_main`

search_memories

Semantic search with optional `filters`, `threshold`, `rerank`, `enable_graph`.

search_graph

Search Neo4j entities by name substring. Returns entities + outgoing relationships.

MEM0_LLM_MODEL

_(per-provider)_

MEM0_OLLAMA_THINK

`false`

MEM0_QDRANT_TIMEOUT

_(client default)_

MEM0_TRANSPORT

`stdio`

Priority

Source

get_memory

Fetch a single memory by UUID.

Variable

Default

MEM0_LLM_MAX_TOKENS

`16384`

MEM0_EMBED_PROVIDER

`ollama`

MEM0_PORT

`8081`

Optional

Required only for `gemini`/`gemini_split` graph providers

Layer

Role

get_entity

Get all relationships for an entity (bidirectional: incoming + outgoing).

MEM0_LLM_URL

_(cascades)_

MEM0_COLLECTION

`mem0_mcp_selfhosted`

MEM0_HOST

`0.0.0.0`

MEM0_GRAPH_CONTRADICTION_LLM_MODEL

_(provider-aware)_

MEM0_QDRANT_URL

`http://localhost:6333`

MEM0_GRAPH_THRESHOLD

`0.7`

streamable-http

Modern remote clients

add_memory

Store text or conversation history as memories. Supports `enable_graph`, `infer`, `metadata`.

get_memories

List/filter memories (non-search). Supports `limit` and scope filters.

MEM0_LLM_PROVIDER

_(MEM0_PROVIDER)_