MCP server · Reference servers
Knowledge Graph Memory MCP server
Gives an assistant a persistent local knowledge graph of entities, relations and facts that it can add to and search.
- Maintainer
- Model Context Protocol project (official)
- Licence
- Apache-2.0 AND MIT
- Runs
- Locally (npx)
- Sign-in
- None
- Last activity
- 2026-10-11
Overview
What it does
The Memory server is a Node.js reference server from the MCP project. It stores what an assistant learns as a small knowledge graph in a JSONL file on your machine. Entities have a name, a type and a list of observations, which are single facts, and relations link two entities in active voice, such as works_at.
Use it when you want an assistant to remember project details or preferences across chats without a cloud service. Tools create and delete entities, relations and observations, read the whole graph, search by name, type or observation text, and open nodes by name. The graph is also exposed as a resource that notifies subscribed clients when it changes. Set MEMORY_FILE_PATH to choose where the file lives. Several clients can share one file: writes take a lock file so they take turns, though the README warns this needs a local filesystem.
Tools
What the assistant can do
- Create entities and relations, and add observations to entities
- Delete entities, relations or individual observations
- Read the whole graph or open chosen nodes by name
- Search entities by name, type or observation text
- Expose the graph as a resource with change notifications
Install
Install Knowledge Graph Memory MCP server in your app
You need:
- Node.js with npx
- A writable folder for the memory file (set MEMORY_FILE_PATH to choose it)
Run in your project. --scope local keeps the servers private to you in this project; use user for every project.
claude mcp add --scope local memory -- npx -y @modelcontextprotocol/server-memory
claude mcp add --scope local memory -- cmd /c npx -y '@modelcontextprotocol/server-memory'
Project root. Commit it to share the servers with your team; each person sets the variables in their own shell.
{
"mcpServers": {
"memory": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-memory"
]
}
}
}
- On native Windows (not WSL), the reference servers’ READMEs start npx through `cmd /c`: if a server won’t start, use "command": "cmd" with "args": ["/c", "npx", …].
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json · Windows: %APPDATA%\Claude\claude_desktop_config.json (Settings → Developer → Edit Config). Restart Claude after saving.
{
"mcpServers": {
"memory": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-memory"
]
}
}
}
In your project, or ~/.cursor/mcp.json for every project.
{
"mcpServers": {
"memory": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-memory"
]
}
}
}
In your workspace. VS Code asks for each secret the first time a server starts and stores it securely.
{
"servers": {
"memory": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-memory"
]
}
}
}
macOS/Linux: ~/.config/devin/mcp_config.json · Windows: %APPDATA%\devin\mcp_config.json. Read by the default Devin Local agent and by the legacy Cascade agent.
{
"mcpServers": {
"memory": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-memory"
]
}
}
}
Want it alongside other servers? Open Knowledge Graph Memory Server in the MCP config generator and add the rest; it writes one file per app. The snippets follow the setup in the server’s README, checked on 2026-10-14.
Before you install
- Everything the assistant stores is written in plain text to a local JSONL file; by default it sits in the server’s own directory, so set MEMORY_FILE_PATH to a place you control.
- The assistant can delete entities and observations, and deleting an entity also removes its relations.
- Sharing one memory file between clients relies on exclusive file creation; the README says a network filesystem may not be safe.
- A local MCP server runs with your user account’s permissions. Install it only from the source linked above. See how to choose a safe server.
Why it’s listed
Why we list it
A simple, local and inspectable way to give an assistant memory between sessions, kept by the MCP project.
Related
More MCP servers
- Filesystem MCP ServerLets an assistant read, write, edit, move and search files, but only inside the folders you allow.
- Git MCP ServerLets an assistant check status, read diffs and logs, stage, commit and switch branches in a local Git repository.
- Fetch MCP ServerLets an assistant fetch a web page and read it as Markdown, in chunks, with private addresses blocked by default.
- Sequential Thinking MCP ServerGives an assistant a tool for step-by-step reasoning that it can revise or branch as it works through a problem.
- Time MCP ServerLets an assistant get the current time in any IANA time zone and convert a time between zones.
All MCP serversMCP config generatorGuide: MCP servers in Claude CodeGuide: what is MCP?