← MCP servers · ankimcp

AnkiMCP Server

CAUTIONgrade C · trust 71/100

An Anki addon that implements an MCP server, enabling AI assistants to interact with Anki, the spaced repetition flashcard application.

aianki addonanki mcpmcp

Overview

From the repository's own README, as read at the audited commit.

# AnkiMCP Server (Addon)<div align="center">  <img src="./docs/images/ankimcp.png" alt="Anki + MCP Integration" width="600" />  <p><strong>Seamlessly integrate <a href="https://apps.ankiweb.net">Anki</a> with AI assistants through the <a href="https://modelcontextprotocol.io">Model Context Protocol</a></strong></p></div>An Anki addon that exposes your collection to AI assistants via the [Model Context Protocol (MCP)](https://modelcontextprotocol.io/).## What is this?AnkiMCP Server runs a local MCP server inside Anki, allowing AI assistants like Claude to interact with your flashcard collection. This enables AI-powered study sessions, card creation, and collection management.Part of the [ankimcp.ai](https://ankimcp.ai) project.## Note on First RunOn first run, this addon downloads `pydantic_core` (~2MB) from PyPI. This is required because pydantic_core contains platform-specific binaries (Windows/macOS/Linux) that cannot be bundled in a single addon file.A second native dependency, `rpds` (from `rpds-py`), is handled the same way — but it is almost never downloaded: Anki already ships `rpds` as a transitive dependency of its own `jsonschema`, so the addon just imports it. The download only kicks in on the rare install where that import fails. Both downloads are cached under the addon's `_cache/` directory, so they happen once, not on every launch.## Features- **Local HTTP server** - Runs on `http://127.0.0.1:3141/` by default- **Remote tunnel** - Access your collection from anywhere via a public HTTPS URL- **MCP protocol** - Compatible with any MCP client (Claude Desktop, etc.)- **Auto-start** - HTTP server starts automatically when Anki opens- **Tunnel-friendly** - Works with Cloudflare Tunnel, ngrok, or the built-in tunnel (exposing the HTTP server this way also requires extending the [allowed hosts/origins](#allowed-hosts-and-origins-dns-rebinding-protection))- **DNS-rebinding protection** - The HTTP server validates `Host`/`Origin` headers against a loopback allo

Exposed tools (4) 2 read · 2 write · 0 destructive

ToolRiskDescription
addwriteAdd two numbers.
echo_pingreadReturn the message tagged as a ping.
echo_pongreadReturn the message tagged as a pong.
slowwriteA deliberately slow tool used to trigger the response timeout.

Details

Source
ankimcp/anki-mcp-server-addon
Transports
streamable-http
License
NOASSERTION
Stars
73 · pushed 2d ago

Trust audit

Install with care. The audit found things worth knowing before you trust its output.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeWARN
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfaceWARN
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
declared (5 observation(s))
Network
declared (2 observation(s))
Shell
declared (4 observation(s))
Dependencies
not all pinned
Secrets in source
none-found

Findings (24)

MEDIUMCode injection · code.dynamic_import · CWE-78, CWE-94, CWE-95
anki_mcp_server/__init__.py:119
importlib.import_module(pkg)
MEDIUMCode injection · code.dynamic_import · CWE-78, CWE-94, CWE-95
anki_mcp_server/primitives/essential/resources/__init__.py:6
importlib.import_module(modname)
MEDIUMCode injection · code.dynamic_import · CWE-78, CWE-94, CWE-95
anki_mcp_server/primitives/essential/tools/__init__.py:6
importlib.import_module(modname)
MEDIUMCode injection · code.dynamic_import · CWE-78, CWE-94, CWE-95
anki_mcp_server/primitives/gui/tools/__init__.py:6
importlib.import_module(modname)
MEDIUMAuth / authz · mcp.remote_no_auth · CWE-287, CWE-862
streamable-http
Why it matters. a network transport with no auth environment variable found
Fix. require a token
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/e2e/test_media_security.py:27
("/home/user/.ssh/id_rsa", "no extension"),
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_media_validators.py:102
"id_rsa",               # no extension (ssh key)
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_media_validators.py:133
validate_media_file_path("/photos/image\0.ssh/id_rsa.jpg")
Why it matters. touches a credential store
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
tests/e2e/test_media_security.py:26
("/etc/passwd", "no media extension"),
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
tests/unit/test_media_validators.py:129
validate_media_file_path("/etc/passwd\0.jpg")
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/e2e/test_media_security.py:99
"filename": "../../evil.png",
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_media_validators.py:446
assert sanitize_media_filename("../../evil.jpg") == "evil.jpg"
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_media_validators.py:465
result = sanitize_media_filename("../../../etc/passwd.jpg")
LOWNetwork egress · net.metadata_ip · CWE-200, CWE-319
tests/unit/test_media_validators.py:289
("169.254.169.254", "link-local / cloud metadata"),
Why it matters. cloud metadata endpoint: the classic SSRF credential grab
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
README.md:25
- **Local HTTP server** - Runs on `http://127.0.0.1:3141/` by default
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
README.md:132
"args": ["mcp-remote", "http://127.0.0.1:3141"]
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
README.md:143
claude mcp add anki --transport http http://127.0.0.1:3141/
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
README.md:149
opencode mcp add anki --url http://127.0.0.1:3141/
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
README.md:162
5. Use this URL in your AI client instead of `http://127.0.0.1:3141`
LOWObfuscation / stealth · obf.decode_call · CWE-506, CWE-94
anki_mcp_server/primitives/essential/tools/store_media_file_tool.py:44
return base64.b64decode(data), "base64"
LOWPrivilege escalation / persistence · priv.escalate · CWE-269, CWE-250
.github/workflows/anki-compat.yml:154
sudo apt-get update -y && sudo apt-get install -y xvfb
Why it matters. asks for elevated privileges
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
requirements-dev.txt
pytest, pytest-asyncio, packaging
Why it matters. 3 requirement(s) not pinned with ==
Fix. pin exact versions
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
requirements.txt
mcp, uvicorn, starlette, websockets, packaging, typing-extensions
Why it matters. 6 requirement(s) not pinned with ==
Fix. pin exact versions
LOWPrompt injection · prompt.transfer_instruction · CWE-94, CWE-1427
CLAUDE.md:75
Both HTTP and tunnel transports share the same `Server` object (same handlers, same tools). Each runs its own `Server.run()` with separate streams and session state. Either can be enabled/disabled ind
Why it matters. an instruction to move sensitive data to an outside destination
Fix. remove; a skill never needs the user's secrets off the machine

Gates applied: no_behavioural_pass.

Audited 2026-09-13 · audit v0.4.0 · source sha 69375d39375c · full audit: observations/trust-audit/mcp-server/ankimcp__anki-mcp-server-addon.json · Report an issue or request a re-scan

Audit history

DateSourceVerdictGradeScoreChange
2026-09-1369375d39375cCAUTIONC71source changed, verdict held

Alternatives

Other servers in the same categories, safer ones first.

More from ankimcp

Questions

What is the AnkiMCP Server MCP server?

An Anki addon that implements an MCP server, enabling AI assistants to interact with Anki, the spaced repetition flashcard application.

What tools does AnkiMCP Server expose?

4 in total: 2 read-only, 2 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is AnkiMCP Server safe to connect to an agent?

With care. The audit graded it C (71/100) and found 24 things worth knowing before you trust this server, listed below with the exact line each was found on.

What credentials does AnkiMCP Server need?

No credential environment variables were found in its source, so it appears to need none.

How does AnkiMCP Server run?

It speaks streamable-http, so it runs as a service you connect to over the network.

How current is this page?

The grade is for one exact copy of the source (69375d39375c), read on 2026-09-13. The repository is watched and re-audited when it changes.

Provenance: OBSERVED · read 2026-09-13 · job trust-audit-2026-09-13