Anki Flashcard Integration
STDIOMCP server enabling LLMs to interact with Anki flashcard software through AnkiConnect API.
MCP server enabling LLMs to interact with Anki flashcard software through AnkiConnect API.
A Model Context Protocol (MCP) server that enables LLMs to interact with Anki flashcard software through the AnkiConnect API.
Make sure you have Anki installed with the AnkiConnect add-on
2055492159
Clone this repository:
git clone https://github.com/yourusername/anki-mcp-server.git
cd anki-mcp-server
Install dependencies:
npm install
Build the project:
npm run build
Make sure Anki is running on your computer with AnkiConnect enabled
Start the MCP server:
npm start
Connect your MCP client (e.g., Claude) to this server
The server provides the following tools to MCP clients:
{ "name": "createDeck", "arguments": { "name": "My New Deck" } }
{ "name": "addNote", "arguments": { "deckName": "My New Deck", "modelName": "Basic", "fields": { "Front": "What is the capital of France?", "Back": "Paris" }, "tags": ["geography", "europe"] } }
{ "name": "searchNotes", "arguments": { "query": "deck:\"My New Deck\" tag:geography" } }
The server configuration is in the config
object in src/index.ts
. You can modify:
ankiConnectUrl
: URL for the AnkiConnect API (default: http://localhost:8765
)apiVersion
: API version for AnkiConnect (default: 6
)defaultDeckName
: Default deck to use if none specified (default: Default
)Cannot connect to Anki
Permission issues with AnkiConnect
MIT License