Memory Bank MCP server

TypeScript-based server for tracking project context across sessions, enabling persistent knowledge sharing through modular, markdown-based memory management with support for multiple development modes.
Back to servers
Provider
Willian Ribeiro Angelo
Release date
Mar 08, 2025
Language
TypeScript
Package
Stats
1.1K downloads
34 stars

Memory Bank MCP is a server that implements the Model Context Protocol, allowing AI assistants to store and retrieve information across sessions. It provides a structured way to maintain context through "Memory Banks" - repositories of information that help track progress, decisions, and context throughout a project's lifecycle.

Installation

You can install and run Memory Bank MCP in several ways:

Using npm

# Install from npm
npm install @movibe/memory-bank-mcp

# Or install globally
npm install -g @movibe/memory-bank-mcp

Using npx (No Installation Required)

# Run with default settings
npx @movibe/memory-bank-mcp

# Run with specific mode
npx @movibe/memory-bank-mcp --mode code

# Run with custom project path
npx @movibe/memory-bank-mcp --path /path/to/project

# Run with custom folder name
npx @movibe/memory-bank-mcp --folder custom-memory-bank

Basic Usage

Memory Bank MCP can be used as a command-line tool with various commands:

# Initialize a Memory Bank
memory-bank-mcp initialize_memory_bank path=./memory-bank

# Track progress on a task
memory-bank-mcp track_progress action="Feature Implementation" description="Implemented feature X"

# Log an important decision
memory-bank-mcp log_decision title="API Design" context="..." decision="..."

# Switch operational mode
memory-bank-mcp switch_mode mode=code

Configuring in Cursor

Cursor is an AI-powered code editor that supports the MCP protocol. Here's how to configure Memory Bank MCP in Cursor:

  1. Verify npx functionality:

    npx @movibe/memory-bank-mcp --help
    
  2. Configure in Cursor settings:

    • Go to Settings (⚙️) > Extensions > MCP
    • Click "Add MCP Server"
    • Set Name: Memory Bank MCP
    • Set Command: npx
    • Set Arguments: @movibe/memory-bank-mcp --mode code (or other mode)
    • Click "Save" and enable the server
  3. Use MCP commands in Cursor:

    • Initialize: /mcp memory-bank-mcp initialize_memory_bank path=./memory-bank
    • Track progress: /mcp memory-bank-mcp track_progress action="Feature Implementation" description="Implemented feature X"
    • Log decision: /mcp memory-bank-mcp log_decision title="API Design" context="..." decision="..."
    • Switch mode: /mcp memory-bank-mcp switch_mode mode=code

Operational Modes

Memory Bank MCP supports different modes to optimize AI interactions for specific tasks:

Code Mode

  • Focus: Code implementation and development
  • Usage: npx @movibe/memory-bank-mcp --mode code
  • Best for: Writing, refactoring, and optimizing code

Architect Mode

  • Focus: System design and architecture
  • Usage: npx @movibe/memory-bank-mcp --mode architect
  • Best for: Planning project structure and architectural decisions

Ask Mode

  • Focus: Answering questions and providing information
  • Usage: npx @movibe/memory-bank-mcp --mode ask
  • Best for: Getting explanations and clarifications

Debug Mode

  • Focus: Troubleshooting and problem-solving
  • Usage: npx @movibe/memory-bank-mcp --mode debug
  • Best for: Finding and fixing bugs

Test Mode

  • Focus: Testing and quality assurance
  • Usage: npx @movibe/memory-bank-mcp --mode test
  • Best for: Writing tests and test-driven development

Memory Bank Structure

Memory Banks use a standardized file structure:

  • product-context.md: Overall project information and goals
  • active-context.md: Current state, ongoing tasks, and next steps
  • progress.md: History of project updates and milestones
  • decision-log.md: Record of important decisions with context and rationale
  • system-patterns.md: Architecture and code patterns used in the project

Custom Directory Configuration

By default, Memory Bank uses a memory-bank directory in your project root. You can customize this:

# Use a custom project path
npx @movibe/memory-bank-mcp --path /path/to/project

# Use a custom folder name
npx @movibe/memory-bank-mcp --folder custom-memory

This would create the Memory Bank at /path/to/project/custom-memory.

Status System

Memory Bank MCP uses status prefixes to indicate its operational state:

  • [MEMORY BANK: ACTIVE]: Memory Bank is available and providing context-aware responses
  • [MEMORY BANK: INACTIVE]: Memory Bank is not available or not properly configured
  • [MEMORY BANK: UPDATING]: Memory Bank is currently being updated

These indicators appear at the beginning of AI responses, providing immediate visibility into whether the AI has access to your project's context.

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later