zim
A MCP server that enables AI models to access and search ZIM format knowledge bases offline
claude mcp add --transport stdio thinkinai-hackathon-zim-mcp-server uvx zim-mcp-server \ --env ZIM_FILES_DIR="Directory containing your ZIM files (e.g., D:\ZIM)" \ --env PYTHONUNBUFFERED="1"
How to use
The ZIM MCP Server provides local, offline access to content stored in ZIM files by exposing tools that let you list available ZIM files, search their contents, and retrieve specific entries. This enables local AI models to perform question answering and information retrieval against offline knowledge resources without requiring an internet connection. The server exposes three primary tools: list_zim_files, which enumerates ZIM files in configured directories; search_zim_file, which searches for a query within a specified ZIM file; and get_zim_entry, which returns a detailed view of a particular article or page within a ZIM file. To use these tools, start the MCP server via your chosen runner (uv/uvx) and then call the tools with the required arguments. The results are returned in structured JSON, including article snippets, paths, and basic metadata, facilitating integration with your local AI workflows.
How to install
Prerequisites:
- Install uv (https://uv.sh) as described for your operating system.
- Clone the repository:
- Install dependencies and prepare environment (as needed by uv-based servers):
- uv sync
- Prepare ZIM files: download and place ZIM files (e.g., Wikipedia, Wiktionary) into a directory you will reference (e.g., D:\ZIM or /home/user/ZIM).
- Start the server using the preferred method (the MCP config can specify a uv/uvx command). Example (adjust paths to your environment):
- uvx zim-mcp-server
- or if using uv directly to run a Python module, ensure the server entry is invoked appropriately and points to your ZIM directory.
Additional notes
Tips and common issues:
- Ensure ZIM files are accessible by the server process and that the path is correctly configured in your environment (ZIM_FILES_DIR).
- If you encounter permission or path issues, verify file permissions and use absolute paths.
- The tools do not require internet access once ZIM files are loaded; ensure offline operation by keeping the ZIM data local.
- When integrating with Claude Desktop or other clients, provide the correct local paths to the server and ZIM directory as shown in the configuration examples.
- If you update ZIM files, restart the MCP server to refresh the index/search data.
- Environment variables can help customize paths and buffering behavior; adjust as needed for your runtime environment.
Related MCP Servers
web-eval-agent
An MCP server that autonomously evaluates web applications.
mcp-neo4j
Neo4j Labs Model Context Protocol servers
Gitingest
mcp server for gitingest
zotero
Model Context Protocol (MCP) server for the Zotero API, in Python
fhir
FHIR MCP Server – helping you expose any FHIR Server or API as a MCP Server.
unitree-go2
The Unitree Go2 MCP Server is a server built on the MCP that enables users to control the Unitree Go2 robot using natural language commands interpreted by a LLM.