Skip to main content
Glama
MCP Project Context Server

MCP Project Context Server

MCP Project Context Server

A Model Context Protocol (MCP) server that provides persistent project context and planning state between Claude Code sessions. This eliminates the need to re-explain project details, current status, and development context every time you start a new coding session.

What It Does

The MCP Project Context Server acts as a persistent memory layer for your development projects, maintaining:

  • Project Information: Name, description, current phase, and status

  • Technology Stack: Frontend, backend, database, infrastructure, and tooling choices

  • Task Management: Development tasks with priorities, status tracking, and dependencies

  • Decision History: Architectural and technical decisions with reasoning

  • Session Continuity: Goals, achievements, and blockers from previous sessions

  • Development Notes: Important observations and insights

Related MCP server: agent-mem0

How It Works

The server implements the Model Context Protocol to provide Claude Code with tools for managing project context:

  1. Project Creation: Initialize new projects with tech stack and current phase

  2. Context Retrieval: Get comprehensive project state and history

  3. Task Management: Create, update, and track development tasks

  4. Decision Recording: Document important technical and architectural decisions

  5. Session Tracking: Maintain continuity between development sessions

  6. Note Taking: Capture important insights and observations

Data is stored as JSON files in a local data directory, making it easy to backup, version control, or inspect manually.

Key Features

  • Persistent Context: Project state survives between Claude Code sessions

  • Technology Stack Awareness: Tracks your preferred technologies and tools

  • Task Prioritization: Organize work with priority levels and status tracking

  • Decision Documentation: Maintain architectural decision records (ADRs)

  • Session Goals: Track what you planned vs what you achieved

  • File-Based Storage: Simple JSON storage that's easy to understand and backup

Prerequisites

  • Node.js 18 or higher

  • pnpm package manager

  • Claude Code CLI tool

Installation

  1. Clone and setup the project:

git clone <repository-url>
cd mcp-project-context
pnpm install
  1. Build the server:

pnpm run build
  1. Make the server executable:

chmod +x dist/index.js

Configuration

Claude Code Setup

  1. Create or edit the Claude Code MCP configuration file:

mkdir -p ~/.claude
  1. Add your server configuration to `~/.claude.json:

{
    "mcpServers": {
      "mcp-project-context": {
        "type": "stdio",
        "command": "/path/to/mcp-project-context/dist/index.js",
        "args": [],
        "env": {}
      }
    }
}

Replace /absolute/path/to/your/mcp-project-context with the actual path to your project directory.

  1. Verify the configuration:

cat ~/.claude/mcp.json

Usage

Once configured, Claude Code will automatically start and connect to your MCP server. You can then use natural language to interact with your project context:

Example Commands

Create a new project:

"Create a new project called 'E-commerce Platform' for building a modern online store using Next.js, Node.js, PostgreSQL, and Docker"

Get current project status:

"What's the current status of my project? Where did we leave off?"

Add development tasks:

"Add a high-priority task to implement user authentication with OAuth"

Record architectural decisions:

"Record that we decided to use Prisma as our ORM because it provides better TypeScript support and easier migrations"

Update task status:

"Mark the authentication task as completed"

Add project notes:

"Add a note that the API rate limiting is causing issues in development"

Available Tools

The server provides these tools to Claude Code:

  • create_project - Initialize a new project with tech stack and description

  • get_project_context - Retrieve comprehensive project state and history

  • list_projects - Show all projects ordered by last access

  • add_task - Create new development tasks with priorities

  • update_task - Modify task status, priority, or details

  • add_note - Capture important observations and insights

  • record_decision - Document architectural and technical decisions

  • start_session - Begin a development session with specific goals

Data Storage

Project data is stored in the data directory:

data/
├── projects/
│   ├── project-uuid-1.json
│   ├── project-uuid-2.json
│   └── project-uuid-3.json
└── sessions/
    ├── session-uuid-1.json
    ├── session-uuid-2.json
    └── session-uuid-3.json

Each file contains structured JSON data that you can inspect or backup as needed.

Development

Project Structure

mcp-project-context/
├── src/
│   ├── index.ts              # Entry point
│   ├── server.ts             # MCP server implementation
│   ├── storage/
│   │   ├── project-store.ts  # File-based storage layer
│   │   └── context-manager.ts # Context management logic
│   └── types/
│       └── project-types.ts  # TypeScript type definitions
├── data/                     # Project data storage
├── package.json
├── tsconfig.json
└── README.md

Available Scripts

  • pnpm run build - Compile TypeScript to JavaScript

  • pnpm run start - Run the compiled server

  • pnpm run dev - Run in development mode with auto-reload

Testing the Server

You can test the server manually:

# Start the server directly
node dist/index.js

# The server will wait for MCP protocol messages via stdin

For interactive testing, use the MCP Inspector:

npx @modelcontextprotocol/inspector node dist/index.js

Troubleshooting

Server Connection Issues

  1. Verify the server builds successfully:

pnpm run build
  1. Check that the executable bit is set:

ls -la dist/index.js
chmod +x dist/index.js
  1. Test the server manually:

node dist/index.js
  1. Verify Claude Code configuration:

cat ~/.claude/mcp.json

Data Directory Issues

If you encounter permission errors, ensure the data directory exists and is writable:

mkdir -p data/projects data/sessions
chmod -R 755 data/

Claude Code Logs

Check Claude Code logs for connection issues:

# The server logs errors to stderr, which Claude Code captures
# Check your terminal output when starting Claude Code

Privacy and Data

  • All project data is stored locally on your machine

  • No data is transmitted to external services

  • JSON files can be easily backed up or version controlled

  • Each developer/machine maintains separate project contexts

Contributing

  1. Fork the repository

  2. Create a feature branch

  3. Make your changes

  4. Add tests if applicable

  5. Submit a pull request

License

MIT License - see LICENSE file for details

Support

For issues related to:

Available Tools

9 tools
add_noteAdd NoteC

Add a note to the project

Inputs: projectId (required), content (required), category.

add_taskAdd TaskC

Add a new task to the project

Inputs: projectId (required), title (required), priority (required), description, +1 more.

create_projectCreate ProjectC

Create a new project with initial context

Inputs: name (required), description (required), currentPhase (required), techStack.

end_sessionEnd SessionC

End current session with summary

Inputs: sessionId (required), achievements, blockers, nextSession.

get_project_contextGet Project ContextC

Get comprehensive project context and current state

Inputs: projectId (required).

list_projectsList ProjectsB

List all projects ordered by last accessed

Inputs: no named parameters.

record_decisionRecord DecisionC

Record an architectural or technical decision

Inputs: projectId (required), decision (required), reasoning (required), impact.

start_sessionStart SessionC

Start a new development session

Inputs: projectId (required), goals (required).

update_taskUpdate TaskC

Update task status or details

Inputs: projectId (required), taskId (required), status, title, +2 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 9 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose targeting different project management functions: project creation/listing, session management, task/note/decision handling, and context retrieval. No tools overlap in functionality, making selection straightforward for an agent.

    Naming Consistency5/5

    All tools follow a consistent verb_noun naming pattern (e.g., add_note, create_project, get_project_context) with clear, descriptive action-object pairs. There are no deviations in style or convention across the set.

    Tool Count5/5

    With 9 tools, the server is well-scoped for project context management, covering core operations like project lifecycle, session handling, and task/note/decision tracking. Each tool earns its place without bloat or gaps.

    Completeness4/5

    The toolset provides strong coverage for project context workflows, including CRUD-like operations for projects, tasks, notes, and decisions, plus session management. A minor gap exists in updating or deleting notes/decisions, but agents can work around this with the available tools.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      A persistent memory server for Claude Code that captures session context and tool outputs to inject relevant history into future sessions. It enables long-term recall through semantic search and automatic context management, allowing for more consistent and context-aware coding interactions.
      253
      AGPL 3.0
    • A
      license
      Not graded
      quality
      D
      maintenance
      Provides persistent cross-session memory for Claude Code, enabling it to remember user preferences, decisions, and project context across new sessions.
      Apache 2.0
    • A
      license
      Not graded
      quality
      D
      maintenance
      Persistent memory for Claude Code — a self-evolving knowledge layer that survives across sessions, grows from every conversation, and surfaces relevant context automatically.
      14
      MIT