概要
What is QGISMCP - QGIS Model Context Protocol Integration?
QGISMCP connects QGIS to Claude AI through the Model Context Protocol (MCP), enabling direct AI-driven project creation, layer management, processing algorithm execution, and custom Python code execution within QGIS.
How to use QGISMCP - QGIS Model Context Protocol Integration?
Install the QGIS plugin by copying the qgis_mcp_plugin folder into your QGIS profile plugins directory and enabling it via the Plugins manager. Configure Claude Desktop by adding the provided JSON block to claude_desktop_config.json, pointing to the qgis_mcp_server.py file. Start the server in QGIS from Plugins > QGIS MCP > QGIS MCP and click "Start Server". Claude will then have access to a set of tools to interact with QGIS.
Key features of QGISMCP - QGIS Model Context Protocol Integration
- Two-way communication between Claude AI and QGIS via a socket-based server.
- Create, load, and save QGIS projects programmatically.
- Add and remove vector or raster layers from the project.
- Execute processing algorithms from the Processing Toolbox.
- Run arbitrary PyQGIS code from Claude (use with caution).
- Render the current map view to an image file.
Use cases of QGISMCP - QGIS Model Context Protocol Integration
- Create a new QGIS project and add multiple vector/raster layers using natural language.
- Execute processing algorithms such as centroid calculation on vector layers.
- Generate choropleth maps with custom classification and color ramps via PyQGIS.
- Load an existing project, inspect layers, and retrieve feature data.
- Automate map rendering and project saving through conversational commands.
FAQ from QGISMCP - QGIS Model Context Protocol Integration
What are the prerequisites for using QGISMCP?
QGIS 3.x, Claude Desktop, Python 3.10 or newer, and the uv package manager are required.
How do I install the QGIS plugin?
Download the repository, copy the qgis_mcp_plugin folder into your QGIS profile’s Python/plugins directory, then enable it in QGIS via Plugins > Installing and Managing Plugins.
How do I configure Claude Desktop?
Edit claude_desktop_config.json to include a new MCP server entry with command: "uv", and provide the absolute path to the directory containing qgis_mcp_server.py in the args.
What tools are available for Claude to use in QGIS?
Fourteen tools are available, including ping,