OpenContext
MCPSTRICT TSZERO-CONFIG

Persistent, Project-Local Memory for AI Coding Agents

Coding agents forget decisions between sessions. OpenContext MCP exposes a lightweight Model Context Protocol server that enables AI agents to read and write durable .opencontext/ markdown rules.

project / .opencontext
tree.opencontext
.opencontext/
  ├── architecture.md
  ├── api-contracts.md
  └── coding_rules.md
previewarchitecture.md
01# Architecture
02
03## Authentication
04
05We use **JWT with refresh tokens**.
06
07### Access Token
08- 15-minute expiry
09- Stored in memory only
10
11### Refresh Token
12- 7-day expiry
13- HttpOnly secure cookie
14- Rotated on each use

Without vs. With OpenContext

AI agents are powerful — but only if they remember what matters.

Without Memory

Session context vanishes

Agents lose all memory of prior decisions, conventions, and architecture between sessions.

Architectural rules get broken

Without persistent rules, agents re-implement patterns that conflict with your codebase.

Agents re-ask conventions

"Should I use Zod or Yup?" — the same question, every session, no memory of past answers.

With OpenContext

Plain .md storage in your repo

Plain markdown files that persist across every session. Agents read before acting.

Zero cloud or account lock-in

Open any .opencontext/ file in your editor. Human-readable, machine-readable, no magic.

Team-wide alignment via Git

Commit shared rules to your repo, or .gitignore for private local context. Your choice.

Get Started in 3 Steps

Go from zero-install setup to a codebase with durable, searchable memory in one guided workflow.

Step 01

Add OpenContext to your MCP Client

Add the OpenContext MCP entry to your client configuration. No global install is required. Your client launches the server via npx over stdio.

Core command

["npx", "-y", "opencontext-mcp"]

Config path

opencode.json / project MCP settings

Transport: stdio
OpenCode config
{
  "mcp": {
    "opencontext": {
      "type": "local",
      "command": ["npx", "-y", "opencontext-mcp"],
      "enabled": true
    }
  }
}

Frequently Asked Questions

Everything you need to know about OpenContext.