# AI Agent Memory Compared: Zekra, mem0, OpenMemory, Zep, Letta and Basic Memory

> Six memory layers for AI agents, compared on how they store, how they recall, how they connect to your tools and how you run them. Each one wins somewhere.

*2026-11-04T08:03:02Z*

**Short answer:** for AI agent memory, pick **Letta** if you want an agent runtime whose memory lives inside the agent; **Zep / Graphiti** if facts change over time and you need to know what was true when; **Basic Memory** if you want plain Markdown files you can read and edit; **mem0 / OpenMemory** for the most widely used memory API with a local MCP option; and **Zekra** if you want one MCP memory shared by Claude Code, Codex, Cursor and Gemini, with dedup on write and Arabic + English search.

I build Zekra, so read this with that in mind. I've tried to describe every project the way its own docs do and linked the sources so you can check. Where I'm unsure I say so. Zekra is the youngest project here and has a single maintainer.

## AI agent memory at a glance

| | Storage | Recall | MCP | Licence | Run it |
|---|---|---|---|---|---|
| **Zekra** | Postgres + VectorChord | vectors + BM25 + rerank + 1-hop graph | native, one-command install | AGPL-3.0 | hosted or Docker Compose |
| **mem0** | vector store + optional graph | semantic + BM25 + entity matching | via OpenMemory | Apache-2.0 | cloud or self-host |
| **OpenMemory MCP** | local (mem0 under the hood) | mem0 search | native | Apache-2.0 (mem0 repo) | Docker, OpenAI key |
| **Zep / Graphiti** | temporal knowledge graph (Neo4j, FalkorDB, Neptune) | graph + semantic + keyword | Graphiti MCP server | Graphiti Apache-2.0; Zep cloud proprietary | self-host Graphiti or Zep cloud |
| **Letta** | memory blocks in context + archival store | agent edits its own memory | Letta agents can use MCP tools | Apache-2.0 | `letta server` or cloud |
| **Basic Memory** | Markdown files + SQLite/Postgres index | full-text + vector (FastEmbed) | native | AGPL-3.0 | local, optional cloud sync |

## mem0 and OpenMemory

[mem0](https://github.com/mem0ai/mem0) is the most widely adopted memory layer of the group. It's Apache-2.0, available as a managed platform at app.mem0.ai or self-hosted, and its docs describe retrieval that mixes semantic search, BM25 and entity matching. In May 2025 the team announced [OpenMemory MCP](https://mem0.ai/blog/introducing-openmemory-mcp), a local-first MCP server with tools such as `add_memories`, `search_memory`, `list_memories` and `delete_all_memories`. Per the [OpenMemory docs](https://docs.mem0.ai/openmemory/overview), running it locally needs Docker and an OpenAI API key; a hosted variant also exists.

**Pick it when** you want the biggest ecosystem, many SDKs and a managed option.

## Zep and Graphiti

[Graphiti](https://github.com/getzep/graphiti) is Zep's open-source (Apache-2.0) temporal context graph. Its distinctive idea is time: facts carry validity windows and are invalidated rather than deleted when something changes, and every fact keeps provenance back to the episode it came from. It runs on Neo4j, FalkorDB or Amazon Neptune and ships an MCP server. Zep's cloud product builds on it with a proprietary engine.

**Pick it when** your agent has to reason about how facts changed over time, and you're happy to run a graph database.

## Letta (formerly MemGPT)

[Letta](https://github.com/letta-ai/letta) is an Apache-2.0 platform for stateful agents, grown out of the MemGPT research. Memory is part of the agent: [memory blocks](https://docs.letta.com/guides/agents/memory-blocks) such as *human* and *persona* stay pinned in the context window, the agent edits them itself, and blocks can be shared between agents. Longer-term material goes to archival memory through tools like `archival_memory_insert` and `archival_memory_search`.

**Pick it when** you're building the agent itself and want memory designed into its runtime, rather than added to Claude Code or Cursor from outside.

## Basic Memory

[Basic Memory](https://github.com/basicmachines-co/basic-memory) (AGPL-3.0) keeps knowledge as Markdown files on your disk, indexed in SQLite (or Postgres) with hybrid full-text and vector search via FastEmbed. Because the source of truth is plain files, you can open them in Obsidian or any editor, and the MCP tools read and write the same notes. There is optional cloud sync.

**Pick it when** you want memory you can read, grep and version yourself, and you mostly work alone.

## Zekra

[Zekra](https://github.com/fadymondy/zekra) (AGPL-3.0) is an MCP-first memory server. One command (`zekra mcp:install claude-code`, or codex, cursor, gemini, claude-desktop) connects a client, and every client shares the same *brains*: one per project or team, with per-agent grants enforced server-side. Each write goes through a decision step (ADD / UPDATE / INVALIDATE / NOOP), so a contradicted fact is replaced instead of duplicated, and forgetting keeps history. Recall fuses vectors and BM25, reranks, and adds a one-hop entity graph, with Arabic and English indexed together. There's a hosted version at [app.zekra.dev](https://app.zekra.dev/register), a Docker Compose stack to self-host, plus web, desktop and mobile apps.

Honest limits: it's new (launched October 2026), it's run by one person, and it has far fewer integrations and users than mem0 or Letta. Its graph is simpler than Graphiti's temporal model.

**Pick it when** you use several AI coding tools and want them to share one memory, or you need good Arabic recall.

## How to choose in one minute

1. **Building your own agent runtime?** Letta.
2. **Facts change and timing matters?** Zep / Graphiti.
3. **Want files you can edit by hand?** Basic Memory.
4. **Want the largest ecosystem or a managed API?** mem0.
5. **Want one memory across Claude Code, Codex, Cursor and Gemini?** Zekra.

New to the idea? Start with [What is an MCP memory server?](/en/blog/what-is-an-mcp-memory-server). To set Zekra up with Claude Code, read [Giving Claude Code a memory that survives sessions](/en/blog/claude-code-memory-across-sessions-mcp).

- **Watch:** [Zekra in 47 seconds](https://youtu.be/juky4ieH018)
- **Ask:** [Zekra Discord](https://discord.gg/99JBJd6FsR)
- **Support the launch:** [Zekra on Product Hunt](https://www.producthunt.com/posts/zekra)
- **Start free:** [app.zekra.dev](https://app.zekra.dev/register)

*Sources checked October 2026. Projects move fast; if something here is out of date, tell me on Discord and I'll fix it.*

---

Source: https://zekra.dev/en/blog/ai-agent-memory-compared-mem0-zep-letta-basic-memory
