Automatic project resolution
Resolve or create projects from repo context automatically, without asking users for a project id every time.
Memory MCP stores architecture, decisions, tasks, warnings, preferences, and session state so your AI tools can resume work exactly where they left off.
Jump directly to the area you need and keep implementation steps easy to follow.
Built for teams that want MCP project memory, Supabase persistent context, AI agent memory, and reliable handoff between OpenCode, Claude Code CLI, Qwen Code, Codex, and native sessions.
Resolve or create projects from repo context automatically, without asking users for a project id every time.
Capture repo path, remote, branch, commit, and working tree status so memory stays aligned with real code changes.
Store what was done, what is left, blockers, and the next step whenever a session ends or changes client.
Document key files, modules, and dependencies so future sessions know how parts of the project relate.
Search saved memory by meaning with embeddings in Supabase, while keeping a lexical fallback for portability.
Keep storage efficient with retention policies, timeline summaries, and JSON or Markdown exports for backup or transfer.
Minimal setup, keyboard-friendly navigation, and responsive guidance for desktop, tablet, and mobile.
Clone the repository and install Python dependencies.
Create a Supabase project and run the provided schema.sql file.
Copy .env.example to .env and add your public values.
Register the server in mcp.json or your MCP-compatible client settings.
Start the server and verify shared memory across interfaces.
In most MCP-compatible clients, you talk to the model normally and it decides which tool to call when tool use is enabled.
You do not need to manually name a tool for common tasks. Ask for the context, ask what changed, or ask to continue the project.
If the client exposes Memory MCP tools, the model can call `load_unified_context`, `capture_project_memory`, `sync_session_state`, or other tools automatically based on your request.
Manual tool calls are useful for debugging, integrations, or when you want exact control over inputs and outputs.
When the client exposes the active repo or workspace, Memory MCP can resolve or create the right project automatically, even if you open a new repo in the IDE.
Resume this project and tell me where we left off.
Load the stored project memory before continuing the refactor.
Save this architecture decision and mark the current task as in progress.
Save everything important from this session in Memory MCP.
If this is a new project, create what you need in Memory MCP and start saving memory automatically.
If a client disables tool use, the model cannot call MCP tools automatically. In that case, enable MCP tools in the client or call the tool explicitly.
You can keep this repository in the folder you prefer. Most users clone it once, keep a private `.env`, and connect multiple IDEs or AI clients to the same MCP server.
Clone the repository, install dependencies, run `pip install -e .`, create `.env`, run `schema.sql` in Supabase, and keep the folder in a stable location.
git clone https://github.com/dannymaaz/memory-mcp.git
cd memory-mcp
python -m venv .venv
pip install -r requirements.txt
pip install -e .
The MCP server only needs three values for normal use: SUPABASE_URL, SUPABASE_KEY, and OWNER_ID. DATABASE_URL is optional and only matters if you also want direct Postgres access for admin tasks or SQL tooling.
SUPABASE_URL=https://your-project.supabase.co
SUPABASE_KEY=your-anon-key
OWNER_ID=your-stable-identifier
DATABASE_URL=postgresql://user:password@host:6543/postgres
SUPABASE_URL and SUPABASE_KEY come from your Supabase project settings. OWNER_ID is not provided by Supabase: you choose a stable identifier such as your GitHub username, company slug, or workspace id and keep using the same value.
The MCP is not Windows-only. After `pip install -e .`, macOS and Linux expose the same `memory-mcp` command, so the same MCP server entry works across platforms.
python3 -m venv .venv
source .venv/bin/activate
cp .env.example .env
Do not copy the server into every project. Keep one stable folder for the MCP server and connect all clients to that same installation.
cp .env.example .env
memory-mcp
After installation, configure clients to launch the same command: memory-mcp. This makes the server behave like any other stdio MCP server.
"command": "memory-mcp"
"env": { "SUPABASE_URL": "..." }
Usually no. When a client is configured with the `memory-mcp` command, it normally starts the server automatically when needed. You only need to run it manually when testing it directly or debugging outside the client.
If an IDE or agent accepts a standard MCP JSON config with an mcpServers entry, you can usually paste the same server block and only adjust environment values.
mcpServers.memory-mcp
Point OpenCode to the shared MCP config or paste the same server block into its settings. PROJECT_MEMORY_INTERFACE is optional if you want to force a client label; most setups can skip it.
opencode --mcp-config mcp.json
Register the same server block in Codex MCP settings, then launch Codex with that configuration.
codex --config mcp.json
Add a local MCP server entry to Claude Desktop using the installed memory-mcp command and the same environment variables from your local setup.
Claude Desktop path by platform
%APPDATA%\Claude\claude_desktop_config.json
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Linux: check your local Claude Desktop app data folder
"command": "memory-mcp"
Run Claude Code with the shared MCP config or the equivalent CLI registration flow.
claude-code --mcp-config mcp.json
Paste the same MCP JSON into Antigravity MCP settings. On Windows, a common config location is shown below.
%USERPROFILE%\.gemini\antigravity\mcp_config.json
"command": "memory-mcp"
Point Qwen Code to the same MCP config or paste the shared server block into its settings. PROJECT_MEMORY_INTERFACE is optional if you want to force a client label.
qwen --mcp-config mcp.json
{
"mcpServers": {
"memory-mcp": {
"command": "memory-mcp",
"env": {
"SUPABASE_URL": "https://your-project.supabase.co",
"SUPABASE_KEY": "your-anon-key",
"OWNER_ID": "your-stable-identifier"
}
}
}
}
Common Antigravity path on Windows
%USERPROFILE%\.gemini\antigravity\mcp_config.json
The API focuses on loading shared context, saving decisions, syncing session state, and measuring interface usage.
resolve_projectResolve or create the current project automatically from repository context.
load_unified_contextLoad durable project memory optimized for the current interface and model.
save_cross_interface_decisionPersist a decision so future sessions inherit the same reasoning.
save_file_memoryStore file summaries, dependencies, and module relationships for later sessions.
save_checkpointSave architecture checkpoints, blockers, functional state, and next steps.
sync_session_stateStore the current working state so another AI client can continue the same task.
capture_project_memoryStore decisions, tasks, checkpoints, file memory, prompts, and session state in one call.
search_semantic_memorySearch memory documents by embedding similarity or lexical fallback.
resume_projectReturn a resume-ready view with progress, warnings, and recommended next action.
get_interface_analyticsMeasure usage patterns across OpenCode, Claude Code CLI, Qwen Code, Codex, and native workflows.
Quick answers for the most common setup and usage questions.
OWNER_ID is a stable identifier that you choose yourself. It is not created by Supabase. Good options include your GitHub username, a team slug, or a workspace id.
No for normal use. SUPABASE_URL and SUPABASE_KEY are enough for the MCP server. DATABASE_URL is only useful for direct Postgres access, admin scripts, or manual SQL tooling.
No. Memory MCP tries to resolve the active project automatically from repository context and can create it when missing.
Yes. If the client exposes tool use, the model can call capture_project_memory to save decisions, tasks, warnings, checkpoints, file memory, prompts, and session state in one step.
Usually no. MCP-compatible clients normally spawn memory-mcp on demand once they are configured with the command.
Use these prompt patterns when you want the model to save, resume, or structure memory with the right level of detail.
Useful when you want long-running planning sessions to save everything important without naming each tool manually.
Use Memory MCP for this project. If you detect important decisions, blockers, tasks, or next steps, save them automatically while we work.
Before we finish, save everything important from this session in Memory MCP and leave me the next recommended step.
Useful for code-heavy work where file memory, dependencies, and checkpoints matter.
Use Memory MCP while we refactor. Document important files, dependencies, architectural decisions, and task progress automatically.
If this repository is new to Memory MCP, create the project automatically and start storing context as we go.
Useful when you want a concise working summary and strong handoff between sessions.
Retoma este proyecto con Memory MCP y dame un resumen de lo hecho, lo que falta y el siguiente paso recomendado.
When we stop, capture the full session in Memory MCP, including decisions, tasks, warnings, prompts, and a checkpoint summary.
Useful when you want delegated coding work to keep the same warnings, tasks, and file memory context.
Use Memory MCP while implementing this task. Keep warnings, task status, and important file memory synchronized as you code.
Before handing control back, save everything important from this coding session in Memory MCP and tell me the next safe step.
Useful for code generation and refactors where you want memory to stay aligned with module relationships and checkpoints.
Use Memory MCP during this refactor. Save architectural decisions, file relationships, and task progress automatically.
If this repository is new, create the project in Memory MCP and start capturing context as we modify the codebase.
Switch views to compare OpenCode, Claude Code CLI, and Codex workflows using the same project memory backend.
Load project memory before editing so OpenCode inherits architecture, previous decisions, and active warnings.
Launch OpenCode with the MCP config
opencode --mcp-config mcp.json
Use the same stored memory to resume implementation, debugging, or planning from the last recorded session state.
Launch Claude Code CLI with the MCP config
claude-code --mcp-config mcp.json
Preserve warnings, tasks, and synced session state when handing off coding work to Codex.
Launch Codex with the MCP config
codex --config mcp.json