Anki MCP Desktop MCP Server

Model Context Protocol server for Anki - enables AI assistants to interact with your Anki flashcards

Remote serverstreamable-httpGo

What is the Anki MCP Desktop MCP Server?

Model Context Protocol server for Anki - enables AI assistants to interact with your Anki flashcards

What it actually does

Seamlessly integrate Anki with AI assistants through the Model Context Protocol

Configuration

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

Maintainer setup documentation.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
syncSync with AnkiWeb to pull latest data and push changes
get_due_cardsGet cards that are due for review, optionally filtered by deck (answers omitted unless include_answer: true, default false)
get_cardsGet cards with flexible filtering by state (due, new, learning, suspended, buried) and deck (answers omitted unless include_answer: true, default false)
present_cardShow a card for review with its question/front side
rate_cardRate card performance (Again, Hard, Good, Easy) and schedule the next review
forgetCardsReset cards to new, discarding their scheduling without recording a review
setDueDateReschedule cards to become due in N days ("0", "3-7", "1!"), without recording a review
areSuspendedCheck suspension state for one or more cards without changing anything
suspendSuspend cards so they are skipped during review until unsuspended
unsuspendUnsuspend cards so they return to normal review
listDecksList all decks, optionally with per-deck study-queue statistics
deckStatsGet comprehensive statistics for a single deck (study queue, true card-state counts, ease/interval distributions)
createDeckCreate a new empty deck (supports Parent::Child, max 2 levels)
changeDeckMove cards to a different deck (created if it doesn't exist)
addNoteCreate a single note with specified fields and tags
addNotesBatch-create up to 100 notes sharing a deck and model (partial success supported)
findNotesSearch for notes using Anki query syntax (deck:, tag:, is:due, etc.)
notesInfoGet detailed information about notes (fields, tags, note type, card IDs; CSS comes from modelStyling)
updateNoteFieldsUpdate existing note fields (CSS-aware, supports HTML content)
deleteNotesDelete notes and all associated cards (destructive, requires confirmation)
getTagsGet all tags in the collection (use first to avoid duplication)
addTagsAdd space-separated tags to specified notes
removeTagsRemove space-separated tags from specified notes
replaceTagsRename a tag across specified notes
clearUnusedTagsRemove orphaned tags not used by any notes (destructive)
getMediaFilesNamesList media files in collection.media, optionally filtered by pattern
retrieveMediaFileDownload a media file as base64 content
storeMediaFileUpload media from base64 data, an absolute file path, or a URL
deleteMediaFileRemove a media file from collection.media (destructive)
modelNamesList all available note types/models
modelFieldNamesGet field names for a specific note type
modelStylingGet CSS styling information for a note type
modelTemplatesGet the card templates (Front and Back HTML) for a note type
createModelCreate a new note type with custom fields, card templates, and CSS (e.g., RTL models)
updateModelStylingUpdate the CSS styling for an existing note type (applies to all its cards)
updateModelTemplatesUpdate the card templates (Front and Back HTML) for an existing note type (applies to all its cards)
addModelFieldAdd a new field to an existing note type (appended at the end or inserted at a specific position)
removeModelFieldRemove a field from an existing note type (deletes its content from all notes; requires explicit confirmation)
renameModelFieldRename a field in an existing note type (Anki rewrites references to the old name in the card templates)
repositionModelFieldChange the position of a field within an existing note type
collection_statsAggregated statistics across all decks with per-deck breakdown and collection-wide card-state counts
review_statsReview history analysis (temporal patterns, retention metrics, study streaks)
guiBrowseOpen the Card Browser and search for cards
guiSelectCardSelect a specific card in the Card Browser
guiSelectedNotesGet IDs of notes currently selected in the Card Browser
guiAddCardsOpen the Add Cards dialog with preset note details
guiEditNoteOpen the note editor for a specific note
guiDeckOverviewOpen the Deck Overview dialog for a specific deck
guiDeckBrowserOpen the Deck Browser dialog
guiCurrentCardGet info about the current card in review mode (includes the answer; errors outside review mode)
guiShowQuestionShow the question side of the current card
guiShowAnswerShow the answer side of the current card
guiUndoUndo the last action in Anki

How to install the Anki MCP Desktop MCP Server

{
  "mcpServers": {
    "anki-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@ankimcp/anki-mcp-server",
        "--stdio"
      ],
      "env": {
        "ANKI_CONNECT_URL": "http://localhost:8765"
      }
    }
  }
}

From the project documentation. Replace placeholders and example paths before connecting.

Configuration

VariableDescriptionRequired
ANKI_CONNECT_URLDeclared in the maintainer’s client configuration.Check documentation

Example prompts to try

  • “Use Anki MCP Desktop to guiBrowse.”
  • “Use Anki MCP Desktop to guiSelectCard.”
  • “Use Anki MCP Desktop to guiSelectedNotes.”

Frequently asked questions

Model Context Protocol server for Anki - enables AI assistants to interact with your Anki flashcards Confirm the tools offered by your installed version in the connected client. Tool availability and permissions depend on the server and account configuration.