Skip to main content
Guide9 min read·Updated August 8, 2026
🧩

Best AI Agent Skills for Memory and Context (2026)

B

A. Frans

Published August 8, 2026

Agent SkillsMemoryContext EngineeringClaude CodeMCP

Before you install anything from this list, run /memory in Claude Code and look at what comes back.

A large share of the "give your agent memory" projects on GitHub were built when agents had none. That is no longer the situation. Claude Code ships two memory systems of its own, both on by default, and if you install a third-party memory layer without knowing that, you end up paying context tokens twice for the same recall.

So this page is ordered the way the decision goes: what you already have, what it does not do, and which skills fill those specific gaps.

What Claude Code already gives you

Two mechanisms carry knowledge between sessions, and they do different jobs.

CLAUDE.md files are instructions you write. They load at the start of every conversation, in a fixed order from broadest to most specific scope:

ScopeLocationShared with
Managed policy/etc/claude-code/CLAUDE.md on Linux, C:\Program Files\ClaudeCode\CLAUDE.md on WindowsEveryone in the organization
User~/.claude/CLAUDE.mdJust you, all projects
Project./CLAUDE.md or ./.claude/CLAUDE.mdYour team, via source control
Local./CLAUDE.local.mdJust you, this project
Files above your working directory load in full at launch; files in subdirectories load when Claude reads something in them. You can pull in other files with @path/to/file syntax, which nests up to four hops deep. Anthropic's own guidance is to keep each file under 200 lines, because these load into context every session and longer files reduce how consistently the instructions get followed.

Auto memory is the other half, and it is the one people miss. Claude writes it, not you. It lives at ~/.claude/projects/<project>/memory/, keyed off the git repository, so every worktree of the same repo shares one directory. There is a MEMORY.md index plus topic files, and only the first 200 lines or 25KB of that index loads at session start. Topic files are read on demand.

It is on by default. Turn it off per project with autoMemoryEnabled: false, globally with the /memory toggle, or with the CLAUDE_CODE_DISABLE_AUTO_MEMORY=1 environment variable. Point it somewhere else with autoMemoryDirectory.

That is a real memory system, free, with no install step and no vector database to run.

The four gaps worth paying for

Knowing the built-in behavior tells you exactly where it stops.

It is machine-local. Auto memory files are not shared across machines or cloud environments. Two laptops means two separate memories of the same repo, and a teammate gets nothing.

Subagents start blank. The main conversation's auto memory is not loaded into subagents. The exception is a fork, which inherits the parent conversation. Subagents can keep their own memory with the memory field in their configuration, but that is a separate directory, not a shared one.

The index has a hard ceiling. Everything past 200 lines or 25KB in MEMORY.md is dropped on the next load. For a long-running project, curation becomes a chore someone has to do.

It is scoped to Claude Code. Nothing you accumulate there is visible to Cursor, to a web chat, or to an application you are building.

Each skill below targets one or more of those. None of them targets all four.

The shortlist

ProjectWhat it isStarsLicenseBest for
claude-memCLI installer plus hooks~90kApache 2.0Session continuity in Claude Code
supermemoryHosted service and API~29kMITMemory shared across tools and apps
LettaStandalone agent framework~24kApache 2.0Building an agent where memory is the architecture
HindsightDocker service~19kMITSelf-hosted memory with an OpenAI-compatible backend
MemoriPython memory engine~16kCheck repoSQL-backed memory for your own agents
MemUMemory framework~14kCheck repoLong-horizon companion and assistant agents
codebase-memory-mcpMCP server~38kMITCode intelligence rather than conversation recall
Agent Skills for Context EngineeringSkill collection~18kMITPractice and technique, not storage
Star counts read from GitHub on 2026-08-08 and move fast in this category. Treat them as a rough popularity signal, not a quality score.

claude-mem, if the problem is "I lost my thread"

This is the one built specifically for the situation where you close a terminal on Friday and open a new one on Monday. It compresses what happened in a session into semantic summaries and injects the relevant parts into later sessions, storing everything in a bundled SQLite database with a Chroma index for hybrid keyword and semantic search.

Install: npx claude-mem install

It is also published through the plugin marketplace, which is the route to prefer if you want the update path handled for you: run /plugin marketplace add thedotmack/claude-mem and then /plugin install claude-mem.

Maintained by Alex Newman. The README states Apache 2.0, though GitHub classifies the licence file as non-standard rather than matching it to a known template, so read the file itself if licensing is something you have to clear internally. There is an optional cloud sync to cmem.ai, which is worth a deliberate decision rather than an accepted default, because it is the point where your session history leaves your machine.

The honest caveat: claude-mem overlaps with auto memory more than it did a year ago. What it still adds is compression and retrieval across a long history, where auto memory gives you a hand-curated index with a hard size cap.

supermemory, if the problem is "only one tool remembers"

Supermemory is a hosted memory engine with an API, not a Claude Code skill. That distinction matters for how you evaluate it: you are adding a service dependency, not a markdown file.

The reason to accept that is the one gap nothing local closes. If you want the same memory available to Claude Code, to an app you are shipping, and to a chat interface, you need a service in the middle. There is a separate claude-supermemory integration from the same team for the Claude Code side specifically.

Check the current pricing page yourself before you commit a workflow to it. Hosted memory is a category where free tiers move.

Letta, MemU, and Memori, if you are building the agent

These three are frameworks, not things you bolt onto Claude Code, and they belong in a different mental bucket.

Letta descends from the MemGPT research line, where the interesting idea is an agent that manages its own context window as a memory hierarchy rather than treating the window as a fixed budget. MemU targets long-horizon agents that need to hold a relationship over months. Memori is the most conventional of the three: a memory engine that puts state in SQL, which is a genuine advantage if your organization already knows how to back up and audit a database.

If your goal is "make Claude Code better today," none of these is your answer. If your goal is "ship a product with an agent in it," this row of the table is where you should be looking.

Licensing note on these two: Letta is Apache 2.0, but GitHub does not match Memori's or MemU's licence files to a standard template. That usually means a modified or dual licence. Open the file before you build a product on either.

codebase-memory-mcp, for a different kind of remembering

Worth separating out because the name misleads. This is an MCP server that indexes a codebase for fast structural lookup. It remembers your code, not your conversation. It pairs well with the others rather than competing with them, and it is the right tool when the recurring cost is Claude re-reading the same files to rediscover the same structure.

Hindsight, and a trust note

Hindsight is worth a careful read of what it is. It is a standalone memory service you run in Docker, from Vectorize.io, under MIT. The repository does publish a documentation skill you can add to Claude Code, installed with npx skills add https://github.com/vectorize-io/hindsight --skill hindsight-docs, but that skill gives your agent the docs. It is not the memory system.

This is the most common category error in the agent skills space generally, and it is worth stating as a rule: a repository being listed as a skill does not make it a skill. Some are MCP servers, some are frameworks, some are standalone applications, and a few are just curated lists. Open the repository and look for a SKILL.md before you assume how it installs.

Context engineering as practice, not storage

Agent Skills for Context Engineering and the smaller context-engineering-kit are collections of technique rather than infrastructure. They encode how to structure what goes into a context window: what to load eagerly, what to defer, how to write instructions an agent will follow.

The unglamorous truth is that this category often beats the storage category. A 150-line CLAUDE.md that says the right things outperforms a vector database full of session transcripts, because the failure mode with agents is rarely that the information was unavailable. It is that the right information was buried under three thousand tokens of things that did not matter.

How to choose

Work down this list and stop at the first line that describes you.

  • Your agent forgets project conventions between sessions, and you have not written a CLAUDE.md yet. Write one. Run /init to generate a starting point, then trim it to the things Claude could not have discovered on its own.
  • It forgets what you did yesterday, across many sessions on one machine. Auto memory already covers a lot of this; add claude-mem if you need retrieval over a longer history than a 200-line index can hold.
  • You work from two machines, or a teammate needs the same context. You need a hosted layer. Supermemory, or Hindsight if the data must stay on your own infrastructure.
  • Claude re-reads the same files every session to rebuild a mental model of the codebase. codebase-memory-mcp.
  • You are building an agent product. Letta, MemU, or Memori, and evaluate them as frameworks against your stack.
  • Your context window fills up and quality drops. No storage tool fixes this. Read the context engineering material.

Security, briefly

Every project here except the built-in memory runs third-party code with access to your session history. That history routinely contains file paths, internal architecture, and sometimes credentials that appeared in a terminal.

Three checks before you install any of them: confirm the license is one your employer accepts, confirm whether the project sends anything off your machine by default, and read what the install command runs rather than pasting it because it appeared in a README. npx and uvx commands execute code from a package registry immediately. That is normal, and it is still worth a look at the package before you run it.

If you are choosing tools rather than skills, the memory and knowledge products we track sit in the tools directory, and there is a broader roundup for developers.

Share this article

📬

Get More AI Tool Guides

New comparisons and guides every week. Join thousands of professionals staying ahead of the AI curve.