Claude History

v1.0.0Knowledge & Memorystable

MCP server for searching and surfacing Claude Code conversation history

claudeclaude-codeconversation-historymcpmodel-context-protocol
Share:
65
Stars
0
Downloads
0
Weekly
0/5

What is Claude History?

Claude History is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp server for searching and surfacing claude code conversation history

MCP server for searching and surfacing Claude Code conversation history

This server falls under the Knowledge & Memory and Developer Tools categories on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • MCP server for searching and surfacing Claude Code conversat

Use Cases

Search Claude Code conversation history.
Surface past interactions for context.
Retrieve and reference previous conversations.
jhammant

Maintainer

LicenseMIT
Languagetypescript
Versionv1.0.0
UpdatedMar 14, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx claudehistorymcp

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Claude History

Claude History MCP is a TypeScript MCP server that indexes and searches your Claude Code conversation history stored in ~/.claude/projects/, giving your AI assistant the ability to retrieve past solutions, find recurring patterns, summarize previous sessions, and inject relevant historical context into new conversations. It exposes nine tools covering full-text search with filter syntax, error resolution lookup, project listing, pattern discovery, and optional cloud sync — making it practical for developers who want their AI assistant to remember and build on previous work rather than starting from scratch each session.

Prerequisites

  • Node.js with npm installed
  • Claude Code installed with existing conversation history in ~/.claude/projects/
  • Git (for cloning the repository)
  • Optional: a cloud storage account and API key if using the cloud sync features (CLAUDE_HISTORY_API_URL and CLAUDE_HISTORY_API_KEY)
  • An MCP-compatible client — Claude Code is the primary supported client
1

Clone and install dependencies

Clone the ClaudeHistoryMCP repository and install the Node.js dependencies.

git clone https://github.com/jhammant/ClaudeHistoryMCP.git
cd ClaudeHistoryMCP
npm install
2

Build the project and index your history

Compile the TypeScript source and build the search index from your Claude Code conversation history.

npm run build
npm run build-index
3

Add the server to Claude Code

Register the MCP server with Claude Code, pointing to the compiled index.js file. Replace the path with your actual installation directory.

claude mcp add claude-history -- node "/path/to/ClaudeHistoryMCP/dist/index.js"
4

Install the post-session hook (optional)

Install the session hook to automatically update the search index after each Claude Code session completes.

npm run install-hook
5

Configure cloud sync (optional)

If you want to sync history across machines, set the cloud storage environment variables in your MCP client configuration.

{
  "mcpServers": {
    "claude-history": {
      "command": "node",
      "args": ["/path/to/ClaudeHistoryMCP/dist/index.js"],
      "env": {
        "CLAUDE_HISTORY_API_URL": "https://your-server.com",
        "CLAUDE_HISTORY_API_KEY": "your-api-key",
        "CLAUDE_HISTORY_TEAM_ID": "optional-team-uuid"
      }
    }
  }
}

Claude History Examples

Client configuration

Claude Desktop config for the Claude History MCP server (basic, no cloud sync).

{
  "mcpServers": {
    "claude-history": {
      "command": "node",
      "args": ["/path/to/ClaudeHistoryMCP/dist/index.js"]
    }
  }
}

Prompts to try

Example requests once the Claude History MCP server is connected.

- "Search my conversation history for how I solved the Docker network ECONNREFUSED error"
- "Find all sessions where I worked on authentication and used the Bash tool"
- "What patterns appear most often in my Claude Code sessions this month?"
- "Summarize the session where I built the payment integration last week"
- "List all my projects and show me which ones I've worked on most recently"
- "Search my history for any TypeScript generics issues I've solved: project:myapp after:2024-01-01"

Troubleshooting Claude History

Search returns no results even though conversation history exists

The search index must be built before the server can find anything. Run 'npm run build-index' in the ClaudeHistoryMCP directory to generate the index from your ~/.claude/projects/ history. If you installed the post-session hook, the index updates automatically going forward.

Server fails to start with 'Cannot find module' or path errors

Ensure you ran 'npm run build' to compile TypeScript before starting the server. The dist/index.js file must exist. Also verify the absolute path in your MCP client config matches the actual location where you cloned the repository.

Cloud sync push/pull fails with authentication errors

Verify that CLAUDE_HISTORY_API_URL and CLAUDE_HISTORY_API_KEY are correctly set in your MCP client config env block. The API URL must be a full URL including protocol (https://). Check that your cloud storage server is running and accessible from your machine.

Frequently Asked Questions about Claude History

What is Claude History?

Claude History is a Model Context Protocol (MCP) server that mcp server for searching and surfacing claude code conversation history It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Claude History?

Follow the installation instructions on the Claude History GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Claude History?

Claude History works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Claude History free to use?

Yes, Claude History is open source and available under the MIT license. You can use it freely in both personal and commercial projects.

Browse More Knowledge & Memory MCP Servers

Explore all knowledge & memory servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "claudehistorymcp": { "command": "npx", "args": ["-y", "claudehistorymcp"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Claude History?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides