Content
# @zealgeo/mcp-geo-server
This is a geographic processing tool server based on the Model Context Protocol (MCP), providing spatial analysis functions such as coordinate system conversion, distance calculation, and area calculation.
## Installation
```json
"geo-mcp-server": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@zealgeo/mcp-geo-server"
]
}
```
## Features
Supports conversion between the following coordinate systems:
- BD09 (Baidu Coordinate System)
- GCJ02 (Mars Coordinate System)
- WGS84 (GPS Coordinate System)
- Web Mercator (Web Mercator Projection)
Supported conversion methods:
- BD09 to GCJ02 and vice versa
- WGS84 to GCJ02 and vice versa
- BD09 to WGS84 and vice versa
- Web Mercator to longitude and latitude and vice versa
Supported spatial calculations:
- Calculate polyline distance (supports meters and kilometers)
- Calculate polygon area (supports square meters, square kilometers, and hectares)
- Supports multiple coordinate system inputs (WGS84, GCJ02, BD09)
## MCP Tools
### mcp_geo_convert
Coordinate system conversion tool. Supports mutual conversion between BD09, GCJ02, WGS84, and Web Mercator.
Parameters:
- `method`: Conversion method
- `BD09toGCJ02`: Baidu Coordinate System to Mars Coordinate System
- `GCJ02toBD09`: Mars Coordinate System to Baidu Coordinate System
- `WGS84toGCJ02`: WGS84 to Mars Coordinate System
- `GCJ02toWGS84`: Mars Coordinate System to WGS84
- `BD09toWGS84`: Baidu Coordinate System to WGS84
- `WGS84toBD09`: WGS84 to Baidu Coordinate System
- `WebMercatortoLngLat`: Web Mercator to longitude and latitude
- `LngLattoWebMercator`: Longitude and latitude to Web Mercator
- `longitude`: Longitude value
- `latitude`: Latitude value
### mcp_geo_calculate_distance
Calculate polyline distance. Based on Web Mercator projection for planar distance calculation.
Parameters:
- `coordinates`: Array of polyline coordinate points `[[lon1,lat1], [lon2,lat2],...]`
- `unit`: Length unit (`meters` [default], `kilometers`)
- `coordType`: Input coordinate type (`WGS84` [default], `GCJ02`, `BD09`)
### mcp_geo_calculate_area
Calculate polygon area. Based on Web Mercator projection for planar area calculation.
Parameters:
- `coordinates`: Array of polygon coordinate points `[[lon1,lat1], [lon2,lat2],...]`
- `unit`: Area unit (`square_meters` [default], `square_kilometers`, `hectares`)
- `coordType`: Input coordinate type (`WGS84` [default], `GCJ02`, `BD09`)
## Coordinate System Description
### BD09 (Baidu Coordinate System)
The coordinate system used by Baidu Maps, further encrypted based on GCJ02.
### GCJ02 (Mars Coordinate System)
The geographic information system coordinate system established by the National Administration of Surveying, Mapping and Geoinformation of China, which is an encrypted version of WGS84.
### WGS84
The original GPS coordinate system, widely used in the GPS global satellite positioning system.
### Web Mercator
The projection coordinate system used by web maps, converting spherical coordinates to planar coordinates. It provides more accurate results for distance and area calculations.
## Notes
1. The accuracy of coordinate conversion depends on the quality of the original data.
2. For coordinates outside mainland China, converting between WGS84 and GCJ02 will directly return the original coordinates.
3. Web Mercator coordinates are typically in meters.
4. Distance and area calculations use planar methods based on the Web Mercator projection, suitable for medium to small scale calculations.
5. For extremely long distances or large areas crossing continents, it is recommended to use spherical calculation methods.
6. Polygon area calculations do not require manual closure; the program will automatically handle closure.
You Might Also Like
MarkItDown MCP
markitdown-mcp is a lightweight MCP server for converting various URIs to Markdown.
Github
GitHub MCP Server connects AI tools to GitHub for code management and automation.

apisix
Apache APISIX is an API Gateway for managing APIs and microservices.
opik
Opik is a powerful tool for managing and optimizing machine learning experiments.

MCP Toolbox for Databases
MCP Toolbox for Databases is an open-source server simplifying database tool...

sqlglot
SQLGlot is a no-dependency SQL parser and transpiler supporting 30 dialects.