claudeers.
// MCP Servers

devmemory

🧠 Persistent local-first memory for AI coding agents β€” MCP server + CLI for Claude Code & Cursor. SQLite FTS5, secret redaction, project isolation.

Actively maintained
97/100
last commit 19 days ago
last release none
releases 0
open issues 0

Install with your AI

Paste into Claude Code, Cursor, or any agent β€” it reads the repo and wires the tool into your project.

Install and set up devmemory (npm project) into my current project.
Found on https://claudeers.com/devmemory
Repo: https://github.com/vasikmansuri/devmemory
Homepage/docs: https://www.npmjs.com/package/@vasikmansuri/devmemory
Detected install method: npm β†’ npm install @vasikmansuri/devmemory
Category: mcp-servers. Platforms: cli, api.
Read the repo's README for exact setup and env vars, then install it and wire it into my project.

Claudeers Health Verdict:
active; community-verified: false. Confirm the source before running anything.
// or install directly (npm)
npm install @vasikmansuri/devmemory
// or clone
git clone https://github.com/vasikmansuri/devmemory

// compatibility

Platformscli, api
Operating systemsβ€”
AI compatibilityclaude
LicenseMIT
Pricingopen-source
LanguageTypeScript

Get your FREE $2.50 API credits to access TickAtlas financial data β†—

🧠 DevMemory

Persistent, local-first memory for AI coding agents. An MCP server and CLI for Claude Code, Cursor and other MCP clients.

Stop re-explaining your codebase. DevMemory remembers your project's decisions, architecture, debugging lessons and conventions across AI sessions. It runs 100% on your machine.

Quick start Β· Claude Code Β· Cursor Β· MCP tools Β· CLI Β· Security Β· Docs


✨ Why DevMemory?

AI coding assistants like Claude Code and Cursor forget everything when a session ends. Every new conversation, you explain the same architecture, the same "we tried X and it broke", the same team conventions.

DevMemory gives your AI agent long-term project memory through the Model Context Protocol (MCP):

Without DevMemoryWith DevMemory
πŸ—‚οΈ Project decisionsRe-explained every sessionSaved once, retrieved automatically
πŸ› Debugging lessonsRediscovered the hard wayRecalled when the same symptom appears
πŸ“ Conventions & constraintsForgotten mid-taskIncluded in every relevant context bundle
πŸ”’ PrivacyContext pasted into chatsStored locally in SQLite, never uploaded

πŸš€ Features

  • 🏠 Local-first and private. A single SQLite file at ~/.devmemory/. No cloud, no account, no telemetry, no network port.
  • πŸ”Œ MCP server. 9 tools over stdio, verified with Claude Code. Works with any MCP client.
  • πŸ—ƒοΈ Project-scoped memory. Each repository's knowledge is isolated, and no project can read another's.
  • 🏷️ Structured memory types: decisions, architecture, debugging lessons, conventions, constraints, task context and facts. Each memory has tags, importance, confidence and an optional expiry.
  • πŸ”Ž Fast, explainable search. SQLite FTS5 full-text search with BM25 ranking, weighted by importance, confidence and recency. Every result explains its score.
  • 🧾 Provenance. Every memory records where it came from: source, client, file, PR or commit reference, and timestamps.
  • πŸ” Secret redaction. API keys, tokens, passwords and private keys are redacted before anything is stored.
  • πŸ›‘οΈ Prompt-injection aware. Retrieved memories are wrapped as untrusted data, and instruction-like content is flagged.
  • ♻️ Safe lifecycle. Duplicate detection, conflict surfacing, supersede chains, reversible archiving, and hard deletes that also purge the search index.
  • πŸ“¦ Import and export. Portable JSON with validation, size limits and protection against path traversal and symlinks.
  • 🧰 Developer CLI. 15 commands, JSON output and meaningful exit codes for automation.

πŸ—οΈ How it works

flowchart LR
    subgraph Clients
        CC[πŸ€– Claude Code]
        CU[πŸ–±οΈ Cursor]
        CLI[⌨️ devmemory CLI]
    end
    subgraph DevMemory["DevMemory (local process)"]
        MCP[MCP server<br/>9 tools Β· stdio]
        ENG[Memory engine]
        SEC[πŸ” Secret redaction<br/>+ validation]
        RET[πŸ”Ž FTS5 / BM25<br/>ranking]
    end
    DB[(SQLite<br/>~/.devmemory/devmemory.db)]

    CC -- JSON-RPC over stdio --> MCP
    CU -- JSON-RPC over stdio --> MCP
    CLI --> ENG
    MCP --> ENG
    ENG --> SEC --> DB
    ENG --> RET --> DB

Memory across sessions

sequenceDiagram
    actor Dev as Developer
    participant S1 as Session 1 (Claude Code)
    participant DM as DevMemory
    participant S2 as Session 2 (new day)

    Dev->>S1: "We chose Drizzle over Prisma because of edge runtimes"
    S1->>DM: memory_save(type: decision, ...)
    DM-->>S1: βœ… saved (secrets redacted, provenance recorded)
    Note over S1: Session ends, the agent forgets everything
    Dev->>S2: "Add a new database table"
    S2->>DM: memory_context("database table")
    DM-->>S2: πŸ“‹ Drizzle decision + conventions (with provenance)
    S2-->>Dev: Uses Drizzle correctly, without being re-told

⚑ Quick start

Requires Node.js β‰₯ 22.12.

# 1. Install
npm install -g @vasikmansuri/devmemory

# 2. Verify the CLI is available
devmemory --version

# 3. Register your project
cd ~/code/my-app
devmemory init

# 4. Save knowledge
devmemory remember -t decision --title "Use Drizzle ORM" \
  -c "Drizzle over Prisma: Prisma's engine binary breaks on edge runtimes." \
  --tags db,orm -i 4 --source-ref docs/adr/0003.md

# 5. Find it again
devmemory search "which orm"
devmemory context "touching the data layer"
Install from source
git clone https://github.com/vasikmansuri/devmemory.git
cd devmemory
npm ci && npm run build && npm link
devmemory --version

πŸ€– Connect Claude Code

βœ… Verified end to end with Claude Code 2.1.294.

claude mcp add --transport stdio devmemory -- devmemory mcp

Share it with your team via .mcp.json:

claude mcp add --scope project --transport stdio devmemory -- devmemory mcp

Check the connection with claude mcp list or /mcp. Then try "Save to DevMemory: we deploy with Argo CD", start a new session, and ask "how do we deploy?"

πŸ’‘ Claude Code starts the server in your working directory, and DevMemory finds the nearest registered project automatically, even from subfolders.

πŸ–±οΈ Connect Cursor

⚠️ Configuration follows Cursor's documented format, but has not been tested end to end yet. Add this to .cursor/mcp.json:

{
  "mcpServers": {
    "devmemory": {
      "type": "stdio",
      "command": "devmemory",
      "args": ["mcp", "--project", "${workspaceFolder}"]
    }
  }
}

🧩 MCP tools

ToolDescription
memory_saveSave a memory. Reports duplicates and possible conflicts; can supersede older memories.
memory_searchRanked keyword search with type, tag and status filters.
memory_getFetch one memory with links and lifecycle history.
memory_updateEdit in place; previous values are kept in history.
memory_forgetArchive (reversible) or permanently delete (confirm: true).
memory_listPaginated, filtered listing.
memory_contextA token-budgeted context bundle for the current task.
memory_linkRelate memories: depends_on, conflicts_with, …
memory_statsProject statistics.

⌨️ CLI reference

CommandPurpose
devmemory initRegister the current directory as a project
devmemory rememberSave a memory (-c - reads stdin)
devmemory search <query>Ranked keyword search
devmemory get <id>Full memory with provenance and history
devmemory listBrowse with filters and pagination
devmemory context [query]The context bundle an agent receives
devmemory update <id>Edit a memory
devmemory forget <id>Archive, or --hard --yes to delete
devmemory link <a> <b>Link two memories
devmemory stats Β· projects Β· doctorStatistics, project list, health checks
devmemory export Β· importPortable JSON backup and restore
devmemory mcpRun the MCP server (stdio)

Add --json to any command for machine-readable output.

Exit codes: 0 ok Β· 1 internal error Β· 2 validation Β· 3 not found Β· 4 project not initialized Β· 5 conflict Β· 6 database error Β· 7 I/O or unsafe path.

πŸ“Š Search quality (measured, not claimed)

These numbers come from 36 labelled queries over a 46-memory test project (npm run eval):

MetricAll queriesDirect wordingParaphrased
Recall@50.9441.0000.750
MRR0.9221.0000.650
Precision@5 (max achievable 0.228)0.2170.2290.175

DevMemory uses keyword search, not semantic search, so paraphrased questions with no shared words can miss. Semantic search is on the roadmap.

πŸ” Security & privacy

  • βœ… Runs locally: no telemetry, no network listener, no external API calls.
  • βœ… Secrets are redacted before storage, covering AWS keys, GitHub tokens, OpenAI and Anthropic keys, JWTs, private keys and passwords.
  • βœ… The database file is readable only by your user (mode 0600).
  • βœ… Projects are isolated, and all SQL is parameterized.
  • βœ… Retrieved memories are treated as untrusted data, never as instructions.
  • ⚠️ The database is not encrypted at rest. Use full-disk encryption for extra protection.

Read more in the security model and SECURITY.md.

βš™οΈ Configuration

VariableDefaultPurpose
DEVMEMORY_HOME~/.devmemoryData directory
DEVMEMORY_PROJECTcurrent dirProject to use
DEVMEMORY_SECRET_POLICYredactredact or reject writes containing secrets
DEVMEMORY_EXTRA_TYPESβ€”Extra memory types, comma-separated
DEVMEMORY_LOG_LEVELwarnLog level (stderr only)

πŸ“š Documentation

Architecture Β· Memory model Β· Security model Β· MCP integration Β· Troubleshooting Β· Retrieval evaluation Β· Roadmap Β· Contributing Β· Changelog

πŸ›£οΈ Roadmap

  • Local MCP server, CLI, FTS5 search, secret redaction, project isolation
  • Verified Claude Code integration
  • Optional local embeddings for semantic search
  • End-to-end verified Cursor integration
  • Better tokenization for Chinese and Japanese text
  • Opt-in encryption at rest

🀝 Contributing

Contributions are welcome! Run npm run check (typecheck, lint, 129 tests, build) and see CONTRIBUTING.md.

⚠️ Known limitations

  • Keyword search only (no semantic search yet).
  • Chinese and Japanese text is tokenized coarsely.
  • Moving a project folder requires running devmemory init again.
  • The Cursor integration is unverified.

πŸ“„ License

MIT Β© Vasik Mansuri


If DevMemory saves you from re-explaining your codebase, please ⭐ star the repo!

Keywords: AI memory Β· MCP server Β· Model Context Protocol Β· Claude Code memory Β· Cursor MCP Β· AI coding assistant Β· persistent context Β· long-term memory for LLM agents Β· local-first Β· SQLite FTS5 Β· developer tools

Support

If this project is useful to you, you can support my open-source work:

// faq

What is devmemory?

🧠 Persistent local-first memory for AI coding agents β€” MCP server + CLI for Claude Code & Cursor. SQLite FTS5, secret redaction, project isolation.. It is open-source on GitHub.

Is devmemory free to use?

devmemory is open-source under the MIT license, so it is free to use.

What category does devmemory belong to?

devmemory is listed under mcp-servers in the Claudeers registry of Claude-compatible tools.

5 views
β˜… 14 stars
unclaimed
updated 23 days ago

// embed badge

devmemory on Claudeers
[![Claudeers](https://claudeers.com/api/badge/devmemory.svg)](https://claudeers.com/devmemory)

// retro hit counter

devmemory hit counter
[![Hits](https://claudeers.com/api/counter/devmemory.svg)](https://claudeers.com/devmemory)

// reviews

// guestbook

0/500

// related in MCP Servers

πŸ”“

f.k.a. Awesome ChatGPT Prompts. Share, discover, and collect prompts from the community. Free and open source β€” self-host for your organization with complete…

// mcp-serversf/⟨HTMLβŸ©β˜… 177,810β—· NOASSERTION[ claude ]
πŸ”“

A cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io

// mcp-serversfarion1231/⟨RustβŸ©β˜… 155,814β—· MIT[ claude ]
πŸ”“

πŸͺ¨ why use many token when few token do trick β€” Claude Code skill that cuts 65% of tokens by talking like caveman

// mcp-serversJuliusBrussee/⟨JavaScriptβŸ©β˜… 117,780β—· MIT[ claude ]
πŸ”“

An open-source AI agent that brings the power of Gemini directly into your terminal.

// mcp-serversgoogle-gemini/⟨TypeScriptβŸ©β˜… 108,744β—· Apache-2.0[ claude ]
β†’ see how devmemory connects across the ecosystem