# Anki MCP Server [Health: Active]

**Category:** 📊 Monitoring  
**Repository:** https://github.com/ankimcp/anki-mcp-server  
**GitHub Stars:** 584  
**npm Downloads (last month):** 4589  
**Views:** 7  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/anki-mcp-server

## Description
MCP server for Anki flashcards: adaptive review, notes, media, and deck management via AnkiConnect.

## Tools
Capabilities this server exposes over MCP:

- **sync** — Sync with AnkiWeb to pull latest data and push changes
- **get_due_cards** — Get cards that are due for review, optionally filtered by deck (answers omitted unless `include_answer: true`, default `false`)
- **get_cards** — Get cards with flexible filtering by state (due, new, learning, suspended, buried) and deck (answers omitted unless `include_answer: true`, default `false`)
- **present_card** — Show a card for review with its question/front side
- **rate_card** — Rate card performance (Again, Hard, Good, Easy) and schedule the next review
- **forgetCards** — Reset cards to new, discarding their scheduling without recording a review
- **setDueDate** — Reschedule cards to become due in N days (`"0"`, `"3-7"`, `"1!"`), without recording a review
- **areSuspended** — Check suspension state for one or more cards without changing anything
- **suspend** — Suspend cards so they are skipped during review until unsuspended
- **unsuspend** — Unsuspend cards so they return to normal review
- **listDecks** — List all decks, optionally with per-deck study-queue statistics
- **deckStats** — Get comprehensive statistics for a single deck (study queue, true card-state counts, ease/interval distributions)
- **createDeck** — Create a new empty deck along with any missing parent decks (nested `Parent::Child::Grandchild`, up to 10 levels for a new deck; an existing deck of any depth is reused)
- **changeDeck** — Move cards to a different deck (created if it doesn't exist, with the same deck-name rules as `createDeck`)
- **addNote** — Create a single note with specified fields and tags
- **addNotes** — Batch-create up to 100 notes sharing a deck and model (partial success supported)
- **findNotes** — Search for notes using Anki query syntax (`deck:`, `tag:`, `is:due`, etc.)
- **notesInfo** — Get detailed information about notes (fields, tags, note type, card IDs; CSS comes from `modelStyling`)
- **updateNoteFields** — Update existing note fields (CSS-aware, supports HTML content)
- **deleteNotes** — Delete notes and all associated cards (destructive, requires confirmation)
- **getTags** — Get all tags in the collection (use first to avoid duplication)
- **addTags** — Add space-separated tags to specified notes
- **removeTags** — Remove space-separated tags from specified notes
- **replaceTags** — Rename a tag across specified notes
- **clearUnusedTags** — Remove orphaned tags not used by any notes (destructive)
- **getMediaFilesNames** — List media files in `collection.media`, optionally filtered by pattern
- **retrieveMediaFile** — Download a media file as base64 content
- **storeMediaFile** — Upload media from base64 data, an absolute file path, or a URL
- **deleteMediaFile** — Remove a media file from `collection.media` (destructive)
- **modelNames** — List all available note types/models
- **modelFieldNames** — Get field names for a specific note type
- **modelStyling** — Get CSS styling information for a note type
- **modelTemplates** — Get the card templates (Front and Back HTML) for a note type
- **createModel** — Create a new note type with custom fields, card templates, and CSS (e.g., RTL models)
- **updateModelStyling** — Update the CSS styling for an existing note type (applies to all its cards)
- **updateModelTemplates** — Update the card templates (Front and Back HTML) for an existing note type (applies to all its cards)
- **addModelField** — Add a new field to an existing note type (appended at the end or inserted at a specific position)
- **removeModelField** — Remove a field from an existing note type (deletes its content from all notes; requires explicit confirmation)
- **renameModelField** — Rename a field in an existing note type (Anki rewrites references to the old name in the card templates)
- **repositionModelField** — Change the position of a field within an existing note type
- **collection_stats** — Aggregated statistics across all decks with per-deck breakdown and collection-wide card-state counts
- **review_stats** — Review history analysis (temporal patterns, retention metrics, study streaks)
- **guiBrowse** — Open the Card Browser and search for cards
- **guiSelectCard** — Select a specific card in the Card Browser
- **guiSelectedNotes** — Get IDs of notes currently selected in the Card Browser
- **guiAddCards** — Open the Add Cards dialog with preset note details
- **guiEditNote** — Open the note editor for a specific note
- **guiDeckOverview** — Open the Deck Overview dialog for a specific deck
- **guiDeckBrowser** — Open the Deck Browser dialog
- **guiCurrentCard** — Get info about the current card in review mode (includes the answer; errors outside review mode)
- **guiShowQuestion** — Show the question side of the current card
- **guiShowAnswer** — Show the answer side of the current card
- **guiUndo** — Undo the last action in Anki

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "anki-mcp-server": {
    "command": "npx",
    "args": ["-y","@ankimcp/anki-mcp-server"]
  }
}
```

## Documentation

## What Anki MCP Server MCP server does

Anki MCP Server MCP server gives an AI assistant access to an Anki collection through AnkiConnect. It covers study workflows, collection maintenance, and content creation rather than only read-only lookup. Agents can synchronize with AnkiWeb, retrieve due or filtered cards, show a card front, record a review rating, and change suspension or scheduling state.

The server also supports deck and note operations. An agent can list or create decks, move cards, create notes individually or in batches, search notes with Anki query syntax, update fields, and delete notes with confirmation. Tag operations include adding, removing, replacing, and clearing unused tags.

Media tools list files in Anki's collection.media directory, retrieve files as base64, store files from base64, an absolute path, or a URL, and delete files. Model discovery is available through the modelNames tool, which helps an agent identify note types before creating notes.

## How it works

Requests arrive through MCP and are translated into Anki operations through AnkiConnect. The sync operation pulls current data from AnkiWeb and pushes local changes. Review actions have different effects: rate_card records a performance rating and schedules the next review, while forgetCards resets a card to new without recording a review, and setDueDate changes its due timing without recording a review.

Card retrieval can be limited by deck and state, including due, new, learning, suspended, and buried. The get_due_cards and get_cards tools do not return answers unless include_answer is set to true. Note searches accept Anki query syntax such as deck:, tag:, and is:due.

Batch note creation supports up to 100 notes sharing a deck and model, with partial success possible. Deck creation supports a Parent::Child structure up to two levels. Destructive operations include deleting notes, removing media, and clearing unused tags.

## Setup and configuration

The project documentation identifies AnkiConnect as the connection layer between the MCP server and Anki. The repository also publishes an npm package named @ankimcp/anki-mcp-server and identifies Claude Desktop in its documentation examples.

## Tools and capabilities

- Review due or filtered cards, present card fronts, rate performance, reset scheduling, set due dates, and manage suspension.
- Synchronize with AnkiWeb and inspect deck-level or collection-wide statistics.
- Create, search, update, batch-create, tag, and delete notes.
- List, retrieve, store, and delete collection media files.
- List available note types and use them when creating notes.

## Limitations and notes

Anki MCP Server MCP server is marked beta, so its APIs and features may change. Operations that delete notes, media, or unused tags are destructive. Card answers are hidden by default in the two card retrieval tools.

_Full upstream README: https://allmcps.com/mcp/anki-mcp-server/readme_

