gee-mcp
Download Google Earth Engine satellite imagery as GeoTIFF files for specified coordinates, date ranges, and bands.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@gee-mcpGet a Sentinel-2 image of downtown Los Angeles from last July with RGB bands."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
GEE MCP Server
Python MCP server exposing a tool to download Google Earth Engine imagery as GeoTIFF.
Prerequisites
Google Earth Engine account approved
Python 3.10+
Local Earth Engine auth completed for the user account
Related MCP server: Axion Planetary MCP
Credentials
Server (GEE)
The server supports two auth methods. Use ONE of these:
Service account key file (recommended)
Place
gee-key.jsonin the project root (same folder asserver.py).The file should be a standard Google service account JSON with fields like
type,project_id,private_key_id,private_key,client_email,client_id, etc.Optionally set
GEE_PROJECTin.env(or it will useproject_idfrom the key file).
Environment variables
Set the following in your environment (or
.envif your launcher loads it):
GEE_PROJECT=your-gcp-project-id
GEE_SERVICE_ACCOUNT=service-account@your-project.iam.gserviceaccount.com
GEE_PRIVATE_KEY_PATH=C:\path\to\service-account.json
# Alternative to GEE_PRIVATE_KEY_PATH:
GOOGLE_APPLICATION_CREDENTIALS=C:\path\to\service-account.jsonNotes:
The server automatically detects
gee-key.jsonif present; otherwise it tries env vars, then default user auth.Run
earthengine authenticateonce if you prefer user auth locally.
Client (LLM)
The client uses an LLM for prompt parsing. Create a .env in the project root with:
OPENAI_API_KEY=sk-...
# Optional, defaults to gpt-4o-mini
OPENAI_MODEL=gpt-4o-miniPassing env to the server
When the client spawns the server (stdio), it forwards the most relevant GEE env vars if set:
GEE_PROJECTGEE_SERVICE_ACCOUNTGEE_PRIVATE_KEY_PATHGOOGLE_APPLICATION_CREDENTIALS
If you rely on gee-key.json, no additional env configuration is required.
Setup
python -m venv .venv
. .venv/Scripts/activate # on Windows PowerShell: .venv\Scripts\Activate.ps1
pip install -r requirements.txtAuthenticate Earth Engine (one-time):
earthengine authenticateIf running on a headless server, set service account credentials via env GOOGLE_APPLICATION_CREDENTIALS or use ee.ServiceAccountCredentials in code.
Run Server (MCP over stdio)
python server.pyThe server exposes one tool:
download_satellite_image(DownloadParams) -> str: Downloads a GeoTIFF to a temp file and returns its absolute path.
DownloadParams
latitude(float)longitude(float)start_date(YYYY-MM-DD)end_date(YYYY-MM-DD)scale(int, meters, default 10)buffer_m(int, default 1000)bands(str, comma-separated; defaultB4,B3,B2)dataset(str, defaultCOPERNICUS/S2)
Run Client (CLI)
The CLI connects to the server over stdio, prompts for parameters, and calls the tool:
python client.pyMCP Client Config Example (Cursor / Claude Desktop)
Add a server entry similar to:
{
"mcpServers": {
"gee-mcp": {
"command": "python",
"args": ["server.py"],
"env": {}
}
}
}Notes
Ensure your date window and location intersect the dataset footprint.
For Sentinel-2, the tool prefers the least cloudy image automatically.
Large regions or small scales may produce big downloads; adjust
buffer_mandscaleaccordingly.Don't give too large region to download at once, the split function in server may fails.
Server functions and capabilities
Tools exposed
download_satellite_image(DownloadParams) -> { files: string[], message: string }Downloads one or more GeoTIFFs from Google Earth Engine for a user-defined Area of Interest (AOI).
Inputs (DownloadParams)
Geographic input (provide exactly one):
latitude,longitude(float): point center; usesbuffer_mto create AOIbounding_box(number[4]):[min_lon, min_lat, max_lon, max_lat](preferred for rectangles)region_geojson(string): full GeoJSON for complex polygons
Temporal and data options:
start_date,end_date(YYYY-MM-DD)dataset(string): defaultCOPERNICUS/S2_SR_HARMONIZEDbands(string): comma-separated band names (defaultB4,B3,B2)scale(int, meters): target resolutionbuffer_m(int): only used with point inputmax_cloud_cover(float, %): filter cap for Sentinel-2image_count(int): number of least-cloudy images to download
Processing behavior
Sorts by cloud cover (Sentinel-2) and selects up to
image_countimages.Saves files to
download/with capture date in filename.Preflight size check and automatic tiling:
Estimates pixel count/bytes and splits AOI into quadrants when needed.
If a tile still exceeds GEE size limits, recursively splits further (limited depth) and/or increases
scale(coarsens resolution) until the request fits.
Robust region handling:
Converts
bounding_boxto a rectangular polygon.Uses AOI bounds as the download region.
Logging: detailed execution written to
server.log(authentication, preflight, tiling, retries).
Outputs
Returns
{ files: [absolute_file_paths], message: string }.May return multiple files when AOI is split or multiple dates are requested.
Message indicates if fewer images were available than requested, or if tiling/scale backoff occurred.
Limits and notes
Very large AOIs and/or small
scaleproduce large requests; server will split tiles and increasescaleautomatically to satisfy GEE limits (~48 MB per request for thumbnails/downloads).Cloud-cover filtering currently applies to Sentinel‑2 collections (field
CLOUDY_PIXEL_PERCENTAGE).If you need strict masking to the polygon footprint, consider adding an explicit
clip(AOI)step before download.
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/kuzhang/mcp-gee-satellite-download'
If you have feedback or need assistance with the MCP directory API, please join our Discord server