# Memory for coding agents.  
The session ends. The context stays.

Claude Code, Cursor, Codex, OpenCode, Hermes: each keeps the instructions you write down, and some keep a few notes of their own, but none of them recalls earlier sessions by what they're about or carries what it learned to the next tool unless you give it somewhere to keep it. Supermemory is that place: decisions, conventions, debugging history and preferences, recalled when relevant and shared across every tool you use.

## Files first, then memory

Start with AGENTS.md and CLAUDE.md. They are the right home for repo facts.

Durable, team-owned knowledge about a codebase belongs in Git: architecture, conventions, runbooks, the way this repo does things. It is reviewable in a pull request, deterministic, portable between agents, and easy to delete when stale. No memory system should replace that, and supermemory does not try to.

Memory starts where files stop.

## What files can't hold

| The knowledge                       | Why a file can't hold it                                                                                                                                        |
| ----------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| What the agent learned last session | Written after the session, not before it. Files only know what someone remembered to commit.                                                                    |
| Your preferences as a developer     | Personal, not project. They follow you across every repo, so they belong nowhere in one repo.                                                                   |
| Context shared across tools         | Claude Code, Cursor and Codex each keep their own session memory. A decision only reaches the next tool if someone writes it into a shared file like AGENTS.md. |
| What changed and when               | A file is the latest truth. Memory keeps the current fact on top and the history underneath.                                                                    |

Supermemory sits alongside the files: the agent recalls what it learned in earlier sessions, saves what is worth keeping, and forgets what expired. Repo facts stay in the repo. Everything the repo can't say stays here.

## Claude Code

A plugin, two commands, persistent memory across sessions and projects.

```
# Add the plugin marketplace
/plugin marketplace add supermemoryai/claude-supermemory

# Install the plugin
/plugin install supermemory
```

Create an API key on the [API keys page](https://console.supermemory.ai/keys) in the console, set it as `SUPERMEMORY_CC_API_KEY` in your shell profile, restart the terminal, and it runs on its own:

Automatic recall.

Before Claude sees each substantive prompt, the plugin searches memory with it and adds what is relevant. No tool call, no permission prompt.

Auto-capture.

Conversations and important tool usage are saved for later sessions. Nothing to remember to do.

Team memory.

Everyone in your supermemory organization who works on the same repo reads and writes the same repo memory, so a team works from the same decisions.

Explicit control.

`/supermemory:index` indexes the codebase's architecture; `/supermemory:status` shows where you stand.

The [Claude Code memory guide](https://supermemory.ai/blog/claude-code-memory-rehab/) covers CLAUDE.md, auto memory and the plugin side by side, and a second post [compares Claude Code memory options](https://supermemory.ai/blog/we-added-supermemory-to-claude-code-its-insanely-powerful-now/).

[Claude Code plugin in the docs](https://supermemory.ai/docs/integrations/claude-code)

## Every harness

The same memory, wherever the agent runs.

| Harness        | How it connects                                                                                                   |
| -------------- | ----------------------------------------------------------------------------------------------------------------- |
| Claude Code    | The plugin above, with recall and capture built in                                                                |
| Cursor         | The [Cursor plugin](https://supermemory.ai/blog/cursor-memory-via-mcp/), or the MCP server                        |
| Codex          | The [Codex plugin](https://supermemory.ai/docs/integrations/codex)                                                |
| OpenCode       | The [OpenCode plugin](https://supermemory.ai/blog/opencode-memory/), for OpenCode 1 and 2                         |
| Hermes         | The [Hermes memory provider](https://supermemory.ai/blog/supermemory-will-make-your-hermes-agent-crazy-powerful/) |
| Your own agent | The MCP server or the [API](https://supermemory.ai/docs/quickstart)                                               |

Because it is one memory layer rather than one plugin per tool, a decision saved in Claude Code is there when you open Cursor. The agent changes; the context does not.

The coding plugins key memory to the repository's Git remote, so [every agent working on the same repo](https://supermemory.ai/docs/integrations/cursor#container-tags) reads and writes the same memory. For chat apps, see the [MCP page](https://supermemory.ai/mcp/); for agents you build yourself, start with the [quickstart](https://supermemory.ai/docs/quickstart).

[The supermemory MCP server](https://supermemory.ai/mcp/)

## Self-hosted

Prefer everything on your own machine? The Claude Code plugin works against a local supermemory.

```
npx supermemory local
```

Point the project config at your local API and use the key printed on first boot. Same plugin and API, your hardware. Memories don't move between Local and the hosted service. Local collects telemetry by default; set `SUPERMEMORY_DISABLE_TELEMETRY=1` to turn it off.

[Self-hosting notes in the docs](https://supermemory.ai/docs/integrations/claude-code)

## Start building with supermemory.

Memory and continual learning for any model, any harness. Available through our API, plugins, and MCP.

[Build with supermemory ](https://console.supermemory.ai/)
