Open Source MCP Server

Your Agent
Never Forgets

Persistent memory with semantic search for AI agents. Install in 10 seconds. No cloud. No API keys. Works with Claude Code, Cursor, Windsurf, and any MCP client.

Claude Code
$ claude mcp add memory -- npx mcp-smart-memory
Cursor / Windsurf / Any MCP Client
$ npx mcp-smart-memory
6MCP Tools
100%Local
10sInstall
$0API Costs

Every Session Starts From Zero

Your AI agent loses everything when the session ends. Smart Memory fixes that.

Without Memory
// Every new session...
"What framework are we using?"
"What's the project structure?"
"We already fixed this bug yesterday"
"Re-explaining auth flow for 5th time"
 
// 10+ minutes wasted every session
// Context lost forever
With Smart Memory
// Agent searches memory on start...
memory_recall "project setup"
#1 score: 0.92 — "Next.js 14, App Router"
#2 score: 0.87 — "Auth: JWT + middleware"
#3 score: 0.81 — "Bug #42: fixed race condition"
 
// Instant context. Zero repetition.
// Every session builds on the last.

Interactive Playground

Type a command below. This is what your AI agent sees.

mcp-smart-memory — interactive demo
// Welcome to Smart Memory MCP. Try typing a command below.
// Available: memory_learn, memory_recall, memory_stats, help
 

6 Tools. One Install.

Everything your AI agent needs to build persistent knowledge.

memory_learn

Store Knowledge

Store anything with categories and tags. Persists across sessions. Your agent builds a real knowledge base.

memory_recall

Semantic Search

TF-IDF similarity matching. Finds memories by meaning, not keywords. Natural language queries.

memory_stats

Knowledge Overview

Total entries, categories, access patterns. See what your agent has learned at a glance.

memory_patterns

Pattern Detection

Detect patterns in your knowledge. Tag frequency, co-occurrence, hidden connections.

PRO
memory_suggest

Proactive Suggestions

Context-aware suggestions. Warnings, solutions, best practices. Your agent anticipates needs.

PRO
memory_evaluate

Quality Feedback

Rate entries as useful or not. Boosts high-value memories. Self-improving system.

PRO

How It Works

1

Install

npx mcp-smart-memory

One command. Zero config. No API keys, no cloud, no setup.

2

Learn

memory_learn

Your agent stores knowledge as it works. Decisions, patterns, solutions.

3

Recall

memory_recall

Next session, semantic search finds what matters. No cold start.

Powered by TF-IDF with cosine similarity. Pure JavaScript, zero ML dependencies. Data stays local as JSON in ~/.smart-memory/

0
Memories Stored
0
Developers
0
Recall Accuracy
0
Install Time

Works With Everything

One-line install for every major MCP client.

claude mcp add memory -- npx mcp-smart-memory

That's it. Restart Claude Code and you're done.

// .cursor/mcp.json { "mcpServers": { "smart-memory": { "command": "npx", "args": ["mcp-smart-memory"] } } }

Add to .cursor/mcp.json, restart Cursor.

// Windsurf MCP config { "mcpServers": { "smart-memory": { "command": "npx", "args": ["mcp-smart-memory"] } } }

Add to Windsurf MCP settings, restart.

# Run directly via npx npx mcp-smart-memory # Or add to any MCP config { "mcpServers": { "smart-memory": { "command": "npx", "args": ["mcp-smart-memory"] } } }

Works with any MCP-compatible client over stdio.

Free vs Pro

The free version is genuinely useful. Pro is for power users.

Free
Open source. MIT License.
$0
Free forever
  • memory_learn
  • memory_recall
  • memory_stats
  • Unlimited entries
  • 100% local storage
  • MIT License
  • Pattern detection
  • Proactive suggestions
  • Quality feedback
Install Free

Smart Memory vs Alternatives

The only MCP-native memory system that works with every client.

FeatureSmart Memoryclaude-memmem0Zep
MCP NativeYesPluginSDKSDK
Any MCP ClientYesClaude onlyPythonPython
No Cloud RequiredYesYesNoNo
No API KeyYesYesNoNo
Semantic SearchTF-IDFNoEmbeddingsEmbeddings
Pattern DetectionYesNoNoNo
Proactive SuggestionsYesNoNoNo
Zero DependenciesYesNoNoNo

Common Questions

Any MCP-compatible client: Claude Code, Cursor, Windsurf, Cline, and more. If it supports the Model Context Protocol, Smart Memory works out of the box.
Locally on your machine in ~/.smart-memory/ as JSON files. Nothing leaves your computer. No cloud, no API calls, no telemetry.
Free includes the 3 core tools (memory_learn, memory_recall, memory_stats) with unlimited entries. Pro adds memory_patterns, memory_suggest, memory_evaluate, plus multi-database support, export/import, and auto-categorization.
Yes! Set the SMART_MEMORY_DB environment variable to create separate databases for different projects.
No. After the initial npx install, Smart Memory runs entirely offline. All search and storage happens locally.
Smart Memory uses TF-IDF (Term Frequency-Inverse Document Frequency) with cosine similarity -- the same algorithm search engines used for decades. No GPU, no model downloads, instant results.

Your Agent Deserves
A Memory.

Install in 10 seconds. Free and open source. Pro for $29 if you want the full system.

View on GitHub