MCP AnkiConnect Server

Provides an MCP bridge between Claude and AnkiConnect to manage due cards, fetch cards for review, and submit review ratings.
  • python

0

GitHub Stars

python

Language

6 months ago

First Indexed

3 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "mcp-mirror-samefarrar_mcp-ankiconnect": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "mcp-ankiconnect",
        "mcp-ankiconnect"
      ]
    }
  }
}

You can connect Claude conversations to AnkiConnect through an MCP server to manage flashcards and spaced repetition with simple, conversational prompts. This setup lets you check today’s due cards, retrieve cards for review, and submit your review ratings directly from Claude or another MCP client.

How to use

Use your MCP client to interact with the server’s endpoints to manage your Anki flashcards. You can ask for the number of cards due today, fetch due cards for review, and submit your review ratings. The tools are designed to work smoothly with AnkiConnect so you can review and add flashcards without leaving your chat flow.

How to install

Prerequisites you need before starting:

  • Anki must be running with the AnkiConnect plugin installed (plugin id 2055492159).
  • Disable AppSleep for Anki to improve performance on macOS by running these commands in your terminal:
    defaults write net.ankiweb.dtop NSAppSleepDisabled -bool true
    defaults write net.ichi2.anki NSAppSleepDisabled -bool true
    defaults write org.qt-project.Qt.QtWebEngineCore NSAppSleepDisabled -bool true```
    

Install and configure the MCP server runtime using the following steps.

1) Install and configure Claude Desktop to use your MCP server
2) Add the MCP server configuration to Claude Desktop:
```json
{
  "mcpServers": {
    "mcp-ankiconnect": {
      "command": "uv",
      "args": ["run", "--with", "mcp-ankiconnect", "mcp-ankiconnect"]
    }
  }
}
  1. Restart Anki and Claude Desktop
## Additional setup for debugging and development

If you want to debug MCP server behavior locally, you can use the MCP Inspector. First clone the project, install dependencies, and synchronize the MCP runtime, then start debugging with the inspector URL.

git clone https://github.com/samefarrar/mcp-ankiconnect.git cd mcp-ankiconnect uv sync

uv run mcp dev mcp_ankiconnect/server.py

Upon launching, the Inspector will display a URL you can access in your browser to begin debugging.

Notes on running the MCP server

The MCP server operates as a local process (stdio). You control it by starting it from your MCP runtime (uv) and connecting via the configured client commands. No remote URL is required for this setup.

Available tools

num_cards_due_today

Returns the number of cards due today. Can filter by a specific deck using the optional deck argument.

get_due_cards

Returns cards that are due for review in XML format. Supports optional limit, deck, and today_only parameters.

submit_reviews

Submits a list of reviews with card_id and rating values (wrong, hard, good, easy) and returns a confirmation.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational