GeoServer MCP Server is a Model Context Protocol (MCP) server implementation used to connect large language models (LLMs) to the GeoServer REST API, enabling AI assistants to interact with geospatial data and services. The project is developed by mahdin75, and the current version 0.5.0 (Beta) is under active development, with developers welcome to contribute.
Purpose This project targets geospatial data management and automation scenarios, allowing MCP-compatible AI clients to operate resources such as workspaces, data stores, layers, and styles in GeoServer through natural language or tool calls, and to perform spatial queries and map visualization.
Main Capabilities
- Query and operate GeoServer workspaces, layers, and styles
- Perform spatial queries on vector data
- Generate map visualizations
- Access OGC-compliant web services (WMS, WFS)
- Easily integrate with MCP-compatible clients
Available Tools and Resource Endpoints The tools exposed by the server are organized by category, including: resource endpoints (direct access to GeoServer resources via URI patterns), workspace management, data store and coverage store management, layer management, layer group management, user and user group management, feature type and attribute management, style management, system and service operations, and style XML tools.
Deployment Methods GeoServer MCP has two ways of running; both share the same product concept (operating GeoServer through MCP tools), but they are independent artifacts, and the Python package remains unchanged:
- Python MCP Server: runs standalone (pip, Docker, or Smithery), with the process communicating with the agent via MCP and calling the GeoServer REST API. This is the original and currently released deployment method.
- GeoServer Extension: installs the GeoServer MCP extension directly into GeoServer, exposing a remote MCP endpoint at /geoserver/mcp, without requiring a Python sidecar, targeting GeoServer 2.28.x. For architecture, installation, configuration, security, and client examples, see extension/README.md.
Installation Methods
- Smithery: available for Claude Des via SmitheryAutomatically install the GeoServer MCP Server from ktop.
- Docker: The fastest and best-isolated way to run, suitable for quick testing and evaluation, production deployment, environments where you want to avoid Python dependencies, and consistent cross-system deployment. After running geoserver-mcp, configure the client: for Claude Desktop, edit claude_desktop_config.json; for Cursor, create .cursor/mcp.json.
- pip: Recommended for most users who want to run the server directly on their system, suitable for local running, systems with Python 3.10+ already installed, users who want custom configuration, and development testing. The steps include installing the uv package manager, creating a virtual environment (Python 3.10+, with corresponding commands for Windows PowerShell), installing the package with pip, configuring the GeoServer connection, and starting the server; if using Claude Desktop, no manual startup is needed, while Cursor or a custom client requires running the corresponding code and configuring the client.
- Development installation: Aimed at contributors and developers who want to modify the codebase, suitable for participating in project development, modifying source code, testing new features, and debugging development.
File storage and --storage usage The GeoServer MCP server supports an optional --storage flag, used to specify the base directory for all file read and write operations, such as uploading shapefiles, GeoTIFFs, or exporting results. This flag sets the root folder for file operations for all data-related tools. The relevant tool parameters can provide relative paths (relative to the storage root directory) or absolute paths (bypassing the storage root directory). If --storage is not set, paths are resolved as provided by the user (relative to the working directory or absolute paths). Absolute paths (such as 'C:/input/other.shp') are always used as-is. When running in Docker, the storage directory needs to be mounted as a volume, and relative paths should be used to maintain portability; for remote or container deployments, ensure that the file data is accessible within the container (use Docker volumes if necessary). For exactly which parameters use the storage system, see the tool docstrings.
Client development If you need to develop your own client to interact with the GeoServer MCP server, you can refer to the example client implementation examples/client.py, which demonstrates how to establish a connection with the MCP server,send requests and handle responses, basic error handling and connection management, and example usage of various tools and operations.
Planned features Coverage of raster data management, security and access control, advanced styling capabilities, WPS processing operations, and GeoWebCache integration.
Use cases and limitations Suitable for users who need to manage GeoServer geospatial data, execute spatial queries, and generate map visualizations through an AI assistant. Prerequisites include Python 3.10 or later, a running GeoServer instance with the REST API enabled, an MCP-compatible client (such as Claude Desktop or Cursor), and an internet connection for installing the package. The current version is 0.5.0 Beta, and some features (such as raster data management and secure access control) are still planned. The project uses the MIT License.