Skip to content

Guide

How to add persistent memory to Cursor and Claude via MCP

Cursor and Claude forget everything between sessions. Here is how to give them long-term, shared memory in a few minutes using OctaMem's remote MCP server — no local install.

By the OctaMem teamPublished 5 min read

To give Cursor or Claude persistent memory, connect them to a memory server over MCP (Model Context Protocol). With OctaMem, you add one remote MCP URL — https://mcp.octamem.com — plus your API key, and the assistant gains add and search tools it can call to store and recall information across sessions. Because the memory lives in your OctaMem account rather than the client, the same memories are available in Cursor, Claude Desktop, and Claude.ai.

Step 1: Get an OctaMem API key

Create a free account at platform.octamem.com and copy your API key from the dashboard. The free tier includes 2 GB of memory and full access to the MCP server and SDKs, so you can complete this guide without a paid plan.

Step 2: Connect Cursor

Cursor reads MCP servers from a single mcp.json file — the same on macOS, Windows, and Linux. Create or edit .cursor/mcp.json in your project (or the global config from Cursor Settings → MCP / Tools) and add OctaMem:

.cursor/mcp.json
{
  "mcpServers": {
    "octamem": {
      "url": "https://mcp.octamem.com",
      "headers": {
        "Authorization": "Bearer YOUR_OCTAMEM_API_KEY"
      }
    }
  }
}

Using the Authorization bearer header (shown above) is recommended over putting the key in the URL, because it keeps the key out of logs. Save the file and reopen Cursor so it picks up the new server.

Step 3: Connect Claude Desktop

In the Claude Desktop app (Mac or Windows), open Settings → Connectors, choose Add custom connector, and paste the remote MCP URL https://mcp.octamem.com with your API key. Because it is a remote connector, there is no local server to run.

Claude.ai on the web

The web app works the same way: open Settings → Connectors, add a custom connector, and paste the same URL and key. This is available on Free, Pro, Max, and Team plans.

Step 4: Verify it works

Start a new chat in your assistant and ask:

What OctaMem tools do you have available?

You should see OctaMem’s tools listed (such as search_context and store_memory). Now tell it something worth remembering, end the session, start a fresh one, and ask it to recall — the memory persists because it lives in OctaMem, not in the conversation.

Why use a dedicated memory layer?

You could paste context back into every prompt, but that burns tokens, does not survive across tools, and has no structure or audit trail. A typed memory layer stores facts, events, and procedures separately, tracks where each memory came from, and lets you delete it on request — which matters for teams in regulated industries. Read more on how the OctaMem platform works.

Frequently asked questions

Does Cursor or Claude have built-in long-term memory?

Not across sessions. Cursor and Claude keep context only within a conversation; once it ends or the context window fills, that information is gone. Connecting an external memory layer such as OctaMem over MCP gives them memory that persists across sessions, projects, and even different assistants.

What is MCP?

MCP (Model Context Protocol) is an open standard for connecting AI assistants to external tools and data. A memory server exposes 'add' and 'search' tools over MCP, so any MCP-compatible client — Cursor, Claude Desktop, Claude.ai — can store and recall memory through the same interface.

Do I need to run a local server?

No. OctaMem hosts a remote MCP server at mcp.octamem.com, so you only paste a URL and your API key. There is nothing to install or keep running on your machine.

Is the memory shared between Cursor and Claude?

Yes. Because both connect to the same OctaMem account, a memory stored from Cursor can be recalled in Claude, and vice versa — the memory layer is model- and client-agnostic.

Give your agents memory that lasts.

Start free with 2 GB of persistent memory and full SDK access — no sales call required.