drio
Open app

Anki MCP Server

Source

Catalog onlyCatalog onlySTDIO

Overview

Anki MCP Server is a Model Context Protocol server designed to connect to Anki via AnkiConnect, allowing users to retrieve and analyze leech-tagged cards for improved study efficiency.

To use the Anki MCP Server, ensure Anki and AnkiConnect are running, clone the repository, install dependencies, and start the server. Then, configure Claude Desktop to connect to the MCP server.

  • Connects to Anki via AnkiConnect API - Retrieves cards with "leech" tags for analysis - Provides comprehensive card data for use with Claude Desktop - Easy configuration through environment variables
  1. Analyzing leech cards to improve study habits
  2. Integrating with Claude Desktop for enhanced learning
  3. Customizing study sessions based on card performance

Add to your AI client

Use these steps to connect Anki MCP Server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.

Cursor

Add this to your .cursor/mcp.json file in your project root, then restart Cursor.

.cursor/mcp.json

{
  "mcpServers": {
    "anki-mcp-server-captain-blue210": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

Claude Desktop

Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)

{
  "mcpServers": {
    "anki-mcp-server-captain-blue210": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

Claude Code

Add this to your project's .mcp.json file. Claude Code will detect it automatically.

.mcp.json (project root)

{
  "mcpServers": {
    "anki-mcp-server-captain-blue210": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

VS Code (Copilot)

Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.

.vscode/mcp.json

{
  "servers": {
    "anki-mcp-server-captain-blue210": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

Windsurf

Add this to your Windsurf MCP config file, then restart Windsurf.

~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "anki-mcp-server-captain-blue210": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

Cline

Open Cline settings, navigate to MCP Servers, and add this server configuration.

Cline MCP Settings (via UI)

{
  "mcpServers": {
    "anki-mcp-server-captain-blue210": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-anki-mcp-server-captain-blue210"
      ]
    }
  }
}

FAQ

What is a leech card?

A leech card is a card that a user struggles to remember, often requiring additional review strategies.

Do I need to install anything besides Anki?

Yes, you need to install the AnkiConnect add-on for Anki to enable communication with the MCP server.

How do I troubleshoot connection issues?

Ensure Anki is running, AnkiConnect is installed, and check your firewall settings to allow connections.7:["$","div",null,{"className":"container mx-auto flex flex-col gap-4","children":["$L26","$L27",["$","$L28",null,{"currentProject":{"id":3862,"uuid":"e7257718-bfef-44f2-af27-d128866fb473","name":"anki-mcp-server","title":"Anki MCP Server","description":"","avatar_url":"https://avatars.githubusercontent.com/u/67002842?v=4","created_at":"2025-03-22T02:44:37.846Z","updated_at":"2025-03-22T02:49:11.412Z","status":"created","author_name":"captain-blue210","author_avatar_url":"https://avatars.githubusercontent.com/u/67002842?v=4","tags":"[]","category":"research-and-data","is_featured":false,"sort":1,"url":"https://github.com/captain-blue210/anki-mcp-server","target":"_self","content":"$29","summary":"$2a","img_url":null,"type":null,"metadata":"{\"star\":\"0\",\"license\":\"MIT license\",\"language\":\"JavaScript\",\"is_official\":false,\"latest_commit_time\":\"2025-04-13 23:19:52\"}","user_uuid":null,"tools":null,"sse_url":null,"sse_provider":null,"sse_params":null,"is_official":false,"server_command":null,"server_params":null,"server_config":null,"allow_call":false,"is_innovation":false,"is_dxt":false,"dxt_manifest":null,"dxt_file_url":null,"is_audit":false},"randomProjects":[],"currentServerKey":"$undefined"}]]}]