← Back to directory
G

GrayMatter

Community
Local persistent memory for AI agents.
Category
Dev Tools #11 of 751
Stars
★ 490 Very popular
Transport
stdio (local process)
Runtime
Prebuilt binary
Credentials
No credential needed
License
MIT
Last commit
66FMRS · C

GrayMatter is a local-first persistent memory MCP server distributed as a single binary, with a Go library also available. It supports cross-session fact memory, hybrid retrieval, revisions, and an optional knowledge graph; users manage its configuration and local data. The project publishes token-efficiency and inference-cost benchmarks, but those results are not guarantees for every workload.

Strongest · Documentation 16/20 Weakest · Reliability 10/20

Reliability
10/20
Security and permissions
13/20
Maintenance
13/20
Documentation
16/20
Setup experience
14/20
Why each score
Reliability 10/20
The README describes stdio MCP startup, tool capabilities, error handling, and several read-only checks, along with storage and runtime behavior. However, only the README and manifest were supplied: there are no verifiable CI workflows, committed tests, or MCP handshake results, so initialization and tool-list behavior cannot be confirmed; points are deducted.
Security and permissions 13/20
The material treats memory as untrusted input, says the REST surface binds to loopback with bearer authentication, and discloses local storage and some write behavior. The complete MCP tool permission scope, credential flows, confirmation requirements for writes, and network dependencies are not sufficiently verifiable from the supplied material, so the score is limited. No red-line risk is established by the supplied evidence.
Maintenance 13/20
The project lists an MIT license, version, release and installation paths, and claims CI and coverage gates; it is not archived and has open issues. Verifiable commit history, issue response, dependency update records, and a security response channel were not supplied, so points are deducted.
Documentation 16/20
The README gives substantial information on installation, client setup, tools and CLI usage, storage, limits, troubleshooting, and benchmark methods, and it discloses several edge cases. However, performance and test claims are README assertions, and the supplied material lacks a complete tool-parameter contract and sufficient credential/network detail, so full marks are not justified.
Setup experience 14/20
The README provides Go installation, prebuilt binaries, and package-manager paths, lists several MCP clients, and shows a stdio registration example. The manifest declares only an OCI stdio package without image-pull configuration details, and client configuration and live connectivity were not verified in this static review, so points are deducted.

Static review · not runReviewed 2026-11-29

Read the FMRS scoring method →

Fit and risk

What it can accessReads local filesWrites / deletes local filesConnects to a database

Best for

  • Individuals or teams that want local or self-hosted cross-session memory for Go agents.
  • Users who want persistent memory through an MCP client and can manage a local data store.

Not for

  • Users who need a hosted memory service or cross-project memory federation; the README lists federation as planned work.
  • Users who need a general-purpose knowledge-base UI or automatic repository code analysis; the README says GrayMatter is not a knowledge-base UI and does not read source code.

Required permissions

  • Needs read and write access to its configured data directory for the memory database and related local data.
  • The MCP client must be able to launch the configured `graymatter mcp serve` command and communicate over stdio.
  • If an external embedding provider is configured, its credentials may be needed; keyword-only mode does not require those services.

Risks and side effects

  • Memory facts can become stale; the project documents a default 30-day half-life for unpinned facts, while revised or retired records remain as tombstones until pruned.
  • Recalled memories are untrusted input and should not be treated as instructions.
  • Token savings and inference cost figures are project-reported benchmark results and may vary by task and configuration.

Setup

Before you start

Runtime:Prebuilt binary

OPENAI_API_KEY optionalsecret Optional OpenAI embeddings API key; obtain it from your OpenAI account.
VOYAGE_API_KEY optionalsecret Optional Voyage AI embeddings API key; obtain it from Voyage AI.

The README shows installation with go install github.com/angelnicolasc/graymatter/cmd/graymatter@latest, followed by graymatter init to configure supported clients, or graymatter mcp serve to start the MCP server over stdio. It also documents prebuilt binaries and package manager options.

Check that it works

Confirm GrayMatter’s memory tools appear in your MCP client’s tool list. Ask it to remember a fact, then search for that fact to confirm the connection works.

Troubleshooting

  1. Check that the client's MCP configuration points to an available GrayMatter command, then restart or reconnect the client after configuration changes.
  2. Run `graymatter doctor` for observations about local setup; it does not verify that a client loaded the configuration or certify runtime health.
  3. Check the data directory and `gray.db`; when using a custom directory, use the same directory for preparation, MCP, and hooks.
  4. For an external embedding provider, check its credentials and configuration; keyword retrieval is available when no provider is configured.

Things to try

Once connected, you can ask your AI assistant things like:

  • Remember that Maria prefers Slack over email.
  • Search memory for when to follow up with Maria.

Use cases

Store and retrieve agent facts across sessions.
Use hybrid semantic and keyword retrieval to supply relevant memories for tasks.
Record fact revisions while retaining records of prior values.
Enable a knowledge graph and inspect entity relationships and their supporting facts.

Supported clients

Claude Code
Codex
Cursor
OpenCode
AntigravityPartial support
Windsurf
VS Code Copilot Agent
PiPartial support
ZedPartial support
ClinePartial support

Listed from the project's documentation, not tested by this site.

Overview

GrayMatter is a single Go binary that can run as an MCP server or be used as a Go library to store and retrieve agent memories across sessions. It supports hybrid retrieval, memory revisions, a knowledge graph, and a terminal workbench. The project reports up to 90% fewer context tokens per query after 100 sessions.

Similar servers

Source revision c1b9b77cfa40 Data synced 2026-12-05 Read the FMRS scoring method Markdown

Maintainer badge: embed FMRS score

Paste this Markdown into your repository README to display a live score badge:

README.md
[![FollowMCP](https://followmcp.com/badges/graymatter.svg)](https://followmcp.com/en/servers/graymatter)