Are you the author? Sign in to claim
MCP server that lets Claude run Google Earth Engine
An MCP server that lets Claude run Google Earth Engine.
Ask Claude to build a cloud-free satellite image of anywhere on Earth, compute vegetation indices, pull statistics, or classify land cover, and it actually does it on Google's servers. geeflow is the connector that makes that work: a Model Context Protocol (MCP) server exposing Earth Engine as a set of typed tools, plus a code tool so Claude can run arbitrary Earth Engine Python when a task needs something custom.
Underneath the MCP server is a full Python toolkit (usable on its own via CLI or import), so anything an AI session does, a human can reproduce.
Through Claude (or any MCP client), geeflow can:
execute_code tool runs arbitrary Earth Engine Python for
datasets and analyses the typed tools do not cover (climate, rainfall, temperature,
terrain, custom reducers)# 1. install the MCP server
pip install "geeflow @ git+https://github.com/prahaladuk2208-arch/geeflow#subdirectory=packages/geeflow"
# 2. authenticate Earth Engine once (opens a browser)
earthengine authenticate
# 3. add the server to Claude Code
claude mcp add geeflow -- geeflow-mcp
For Claude Desktop or another MCP client, point it at the geeflow-mcp command instead:
{
"mcpServers": {
"geeflow": { "command": "geeflow-mcp" }
}
}
Then start a session and just ask. A first message tells Claude your project:
Use geeflow. My Earth Engine project is my-gee-project. Build a cloud-free dry-season composite of the area around Mount Kenya for 2022, show me a thumbnail, then tell me the mean NDVI.
Claude will call gee_init, build_composite, compute_indices, thumbnail and
region_stats in order and hand back a viewable image and a number.
Core Earth Engine tools (installed with geeflow):
| tool | what it does |
|---|---|
gee_init | connect to Earth Engine (call once per session) |
catalog_search | keyword search across the data catalog |
dataset_info | metadata for a dataset id |
scene_availability | scene counts per sensor for a place and date range |
build_composite | cloud-free, harmonized composite for a year and month window |
compute_indices | add spectral index bands |
thumbnail | PNG preview URL |
region_stats | per-band mean / median / min-max / stdDev over the region |
sample_polygons | auto-generate labeled training polygons from a land-cover product |
export_composite | export to Google Drive or an Earth Engine asset |
export_tasks | recent export jobs and their states |
execute_code | run arbitrary Earth Engine Python for anything above tools do not cover |
Land-cover classification tools appear automatically when the optional lulc-engine
package is also installed (lulc_validate, lulc_check, lulc_feature_stack,
lulc_analyze, lulc_classify, lulc_collector_script). See
docs/mcp.md for a full worked session.
The same engine works as a normal library and CLI, so nothing depends on an AI being in the loop.
Python:
from geeflow import Season
from geeflow.composite.builder import build_composites
from geeflow.features.indices import add_indices
from geeflow.geometry import point_buffer
from geeflow.session import init_ee
init_ee("my-gee-project")
aoi = point_buffer(lat=-0.15, lon=37.31, radius_m=15000)
composites, sensor, bands = build_composites(
2022, aoi, seasons=[Season(name="dry", months=(1, 3))]
)
with_indices, computed = add_indices(composites["dry"], ["NDVI", "NDMI"], bands)
Land-cover classification from a config file (install the optional package first,
pip install "lulc-engine @ git+https://github.com/prahaladuk2208-arch/geeflow#subdirectory=packages/lulc-engine"):
lulc init --template forest # scaffold a lulc.yaml + folders
lulc validate -c lulc.yaml # resolved year to sensor plan
lulc classify -c lulc.yaml --year 2022 # CV, best model, map, export
Two pip-installable packages:
geeflow (packages/geeflow): the core Earth Engine toolkit and the MCP server.lulc-engine (packages/lulc-engine): an optional land-cover classification
workflow built on geeflow. One lulc.yaml defines a whole project (area, years,
classes, seasons); it compares Random Forest, Gradient Boosting and SVM with
polygon-grouped cross-validation, then exports the map. Send the config to a
collaborator and they reproduce your result.execute_code covers the long
tail so the server is a real connector, not a fixed menu.execute_code executes on your machine with
your Earth Engine login, the same trust as any local Python session. Do not expose the
server to untrusted clients.69 unit tests run with no Earth Engine account needed (the ee module is mocked), plus
opt-in live integration tests against real Earth Engine and an end-to-end MCP protocol
test. CI runs lint and tests on Windows and Linux, Python 3.10 to 3.14. The bundled
example classifies at about 95 percent accuracy on real imagery.
Contributions welcome, see CONTRIBUTING.md.
MIT
Run Claude Code as an MCP server so any agent can delegate coding tasks to it
Browser automation using accessibility snapshots instead of screenshots
Google's universal MCP server supporting PostgreSQL, MySQL, MongoDB, Redis, and 10+ databases
Official GitHub integration for repos, issues, PRs, and CI/CD workflows