mcp-anki-connect
Summary: An MCP server that connects AI agents to Anki through AnkiConnect, letting them read, create, and organize flashcards, decks, note types, tags, media, and GUI actions.
Notes & flashcards:
create_flashcard,add_note,add_notes,can_add_notes,update_note_fields,find_notes,notes_info,add_tags,remove_tags.Decks:
deck_names,deck_names_and_ids,get_decks,change_deck,delete_decks,deck_summary, plus config presets viaget_deck_config,save_deck_config,set_deck_config_id,clone_deck_config_id,remove_deck_config_id.Cards & scheduling:
find_cards,cards_info,cards_to_notes,suspend/unsuspend,are_suspended,are_due,get_intervals.Note types (models):
model_names,model_names_and_ids,model_field_names,model_fields_on_templates.Tags & analysis:
get_tags,tag_summary, andbatch_tag_by_deckto migrate subdeck notes into hierarchical tags.Media files:
retrieve_media_file,store_media_file,delete_media_filein the Anki media folder.Image Occlusion:
list_image_occlusion_notes,get_image_occlusion_note,update_image_occlusion_description,batch_update_io_descriptions.GUI control:
gui_browse,gui_add_cards,gui_deck_browser,gui_deck_review,gui_deck_overview,gui_current_card,gui_show_question,gui_show_answer,gui_answer_card,gui_start_card_timer,gui_exit_anki.Utility/meta:
version,upgrade, andmultifor batching raw AnkiConnect requests.
Provides tools for interacting with a running Anki instance through the AnkiConnect add-on, enabling AI agents to inspect and manage flashcard collections programmatically. Capabilities include creating single and bulk notes/flashcards, editing note fields and tags, searching notes and cards with Anki query syntax, managing decks (listing, moving cards, deleting) and deck configuration presets, working with note types/card templates and CSS styling, checking card states (suspended, due, intervals), handling media files, editing Image Occlusion notes, and controlling the Anki GUI (browsing, review sessions, card creation, answering cards).
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-anki-connect Summarize my Japanese deck and tag all cards with 'vocab'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Anki Connect (mcp-anki-connect)
A Model Context Protocol (MCP) server that provides seamless, high-performance integration with Anki via the AnkiConnect add-on.
Enables AI agents (Antigravity, Claude, etc.) to inspect collections, create notes, manage decks, analyze tag hierarchies, and organize study cards programmatically.
Prerequisites
Install AnkiConnect Add-on in Anki:
Open Anki.
Go to Tools → Add-ons → Get Add-ons...
Enter code:
2055492159Click OK and restart Anki.
Keep Anki running when using the MCP server.
Related MCP server: Anki MCP Server
Installation & Build
# Install dependencies
npm install
# Build TypeScript to dist/
npm run buildMCP Configuration
1. Antigravity IDE (Workspace Configuration)
Add to .agents/mcp_config.json in your workspace:
{
"mcpServers": {
"mcp-anki-connect": {
"command": "node",
"args": [
"dist/index.js"
]
}
}
}2. Claude Desktop
Add to your Claude configuration (%APPDATA%\Claude\claude_desktop_config.json on Windows, ~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"mcp-anki-connect": {
"command": "node",
"args": [
"/path/to/mcp-anki-connect/dist/index.js"
]
}
}
}Tools
Analysis & Batch Organization
deck_summary– Get card counts, total notes, and subdeck distribution in a single token-efficient call.tag_summary– Inspect note and card counts per tag (supports optional prefix filtering likeict).batch_tag_by_deck– Automatically migrate notes from subdecks to hierarchical tags (::).
Flashcard & Note Management
create_flashcard– Create quick front/back flashcards in the default deck.add_note– Create custom notes with specified deck, model, fields, and tags.add_notes– Bulk create multiple notes.update_note_fields– Edit fields on existing notes.find_notes– Search notes using Anki search syntax.notes_info– Retrieve detailed note fields and tags.add_tags/remove_tags– Manage note tags.
Deck Operations & Presets
deck_names– List all decks in collection.deck_names_and_ids– List deck names with internal IDs.change_deck– Move cards to another deck.delete_decks– Delete specified decks.deck_presets_summary– Inspect all unique deck configuration presets across the collection with daily limits, retention targets, review orders, and FSRS stats in a single call.get_deck_config– Retrieve the full configuration group object for a specific deck.save_deck_config– Save and update deck configuration settings and presets.set_deck_config_id– Assign decks to a configuration preset ID.clone_deck_config_id– Clone an existing configuration preset with a new name.remove_deck_config_id– Delete an unused configuration preset by ID.
Note Types & Card Templates (Card Types)
model_names– List all note type/model names in the collection.model_names_and_ids– Map model names to their unique internal IDs.model_field_names– Retrieve field names for a specific note type.model_fields_on_templates– Inspect field mappings on template question and answer sides.model_templates– Retrieve all card templates (Card Types) with front/back HTML for a model.model_template_rename– Rename a card template (card type) within a model.update_model_templates– Bulk update front/back HTML templates on an existing model.model_styling– Get CSS styling rules for a note model.remove_empty_models– Safely purge unused note types/models that have 0 notes.
Card Operations
find_cards– Search cards with query syntax.cards_info– Inspect card review history and states.cards_to_notes– Resolve note IDs from card IDs.suspend/unsuspend– Change card suspension status.are_suspended/are_due– Check card states.get_intervals– Inspect card scheduling intervals.
GUI Control
gui_browse– Open Anki card browser with pre-filled search.gui_deck_browser– Jump to deck selection screen.gui_deck_review– Start review session for a deck.gui_add_cards– Open card creation modal in Anki.
Acknowledgements
Based on the original implementation by spacholski1225/anki-connect-mcp, providing structured Model Context Protocol (MCP) integration for AnkiConnect.
License
MIT
Available Tools
56 toolsadd_noteD
Inputs: fields (required), deckName (required), modelName (required), tags, +1 more.
add_notesD
Inputs: notes (required).
add_tagsD
Inputs: tags (required), notes (required).
are_dueD
Inputs: cards (required).
are_suspendedD
Inputs: cards (required).
batch_tag_by_deckD
Inputs: mappings (required).
batch_update_io_descriptionsD
Inputs: updates (required).
can_add_notesD
Inputs: notes (required).
cards_infoD
Inputs: cards (required).
cards_to_notesD
Inputs: cards (required).
change_deckD
Inputs: deck (required), cards (required).
clone_deck_config_idD
Inputs: name (required), cloneFrom.
create_flashcardD
Inputs: back (required), front (required).
deck_namesD
Inputs: no named parameters.
deck_names_and_idsD
Inputs: no named parameters.
deck_summaryD
Inputs: deckName (required), includeSubdecks.
delete_decksD
Inputs: decks (required), cardsToo.
delete_media_fileD
Inputs: filename (required).
find_cardsD
Inputs: query (required).
find_notesD
Inputs: query (required).
get_deck_configD
Inputs: deck (required).
get_decksD
Inputs: cards (required).
get_image_occlusion_noteD
Inputs: noteId (required).
get_intervalsD
Inputs: cards (required), complete.
get_tagsD
Inputs: no named parameters.
gui_add_cardsD
Inputs: no named parameters.
gui_answer_cardD
Inputs: ease (required).
gui_browseD
Inputs: query (required).
gui_current_cardD
Inputs: no named parameters.
gui_deck_browserD
Inputs: no named parameters.
gui_deck_overviewD
Inputs: name (required).
gui_deck_reviewD
Inputs: name (required).
gui_exit_ankiD
Inputs: no named parameters.
gui_show_answerD
Inputs: no named parameters.
gui_show_questionD
Inputs: no named parameters.
gui_start_card_timerD
Inputs: no named parameters.
list_image_occlusion_notesD
Inputs: limit, offset, deckName, missingOnly.
model_field_namesD
Inputs: modelName (required).
model_fields_on_templatesD
Inputs: modelName (required).
model_namesD
Inputs: no named parameters.
model_names_and_idsD
Inputs: no named parameters.
multiD
Inputs: actions (required).
notes_infoD
Inputs: notes (required).
remove_deck_config_idD
Inputs: configId (required).
remove_tagsD
Inputs: tags (required), notes (required).
retrieve_media_fileD
Inputs: filename (required).
save_deck_configD
Inputs: config (required).
set_deck_config_idD
Inputs: decks (required), configId (required).
store_media_fileD
Inputs: data (required), filename (required).
suspendD
Inputs: cards (required).
tag_summaryD
Inputs: prefix.
unsuspendD
Inputs: cards (required).
update_image_occlusion_descriptionD
Inputs: noteId (required), description (required), tags, header, +1 more.
update_note_fieldsD
Inputs: id (required), fields (required).
upgradeD
Inputs: no named parameters.
versionD
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 56 tools
Many tools have similar purposes (e.g., add_note vs add_notes, deck_names vs deck_names_and_ids) and lack descriptions, increasing the risk of misselection. However, most tool names are specific enough to hint at their function, and distinct categories like GUI control and media management are identifiable.
Most names follow a snake_case pattern, but verbs vary (create_, get_, add_, gui_, batch_) and some are standalone nouns (version, multi) or verbs without objects (upgrade). This mix is readable but not fully consistent.
With 56 tools, the server is far above the recommended 3-15 range and even exceeds the 'heavy' threshold of 25. The scope is broad, but this volume is overwhelming for agents and likely to cause selection fatigue.
The tool set covers most major Anki workflows: decks, notes, cards, tags, media, GUI control, and configuration. However, there are notable gaps such as no explicit delete_note or rename_deck, and update_note_fields exists but no full CRUD for cards beyond suspend/unsuspend.
Related MCP Connectors
Turn text, files, URLs, or photos into Anki flashcard decks from your AI assistant.
Build and study spaced-repetition flashcards with your agent.
List and create Manthan concept-card decks from an AI agent — no AI quota spent for imports.
Connect AI to your flomo notes. Search, create, edit notes and manage tags via MCP.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables interaction with the Anki desktop flashcard application through the Anki-Connect plugin. Supports managing decks, cards, notes, and models, allowing AI assistants to create and query flashcards through natural language.8 npm1ISC
- AlicenseAqualityDmaintenanceEnables AI assistants to manage Anki flashcard collections by creating, searching, and updating cards through a standardized interface. It supports media handling, batch operations, and review scheduling via the AnkiConnect add-on.62MIT
- AlicenseNot gradedqualityDmaintenanceEnables LLMs to interact with Anki via AnkiConnect for creating, searching, and managing flashcards, decks, and note types.1MIT
- AlicenseAqualityCmaintenanceEnables AI assistants to interact with Anki flashcard collections through the AnkiConnect add-on, allowing creation, modification, searching, and management of flashcards and decks.3317 npm27MIT