NASA Image MCP Server
MCP server that provides access to public NASA APIs for obtaining astronomical images, Mars rover photos, Earth satellite imagery, and near-Earth object data with built-in image analysis capabilities.
Get this MCP server
MCP server that provides access to public NASA APIs for obtaining astronomical images, Mars rover photos, Earth satellite imagery, and near-Earth object data with built-in image analysis capabilities.
Installation
PyPI
pip install nasa-mcp-server
UVX
uvx nasa-mcp-server
Configuration
VS Code
{
"servers": {
"nasa-mcp": {
"command": "uvx",
"args": ["nasa-mcp-server"],
"env": {
"NASA_API_KEY": "YOUR_NASA_API_KEY_HERE"
}
}
}
}
Claude Desktop
{
"mcpServers": {
"nasa-mcp": {
"command": "uvx",
"args": ["nasa-mcp-server"],
"env": {
"NASA_API_KEY": "YOUR_NASA_API_KEY_HERE"
}
}
}
}
Available Tools
| Tool | Description |
|---|---|
get_apod |
Retrieve Astronomy Picture of the Day with descriptions, supports date ranges and random images |
get_mars_image |
Access Mars rover photos with various camera options and date filtering |
get_neo_feed |
Retrieve near-Earth object data and asteroid approach information |
get_earth_image_tool |
Obtain Earth satellite imagery from NASA's DSCOVR satellite using the EPIC camera |
get_gibs_image |
Access high-quality Earth satellite imagery from NASA's Global Imagery Browse Services |
get_gibs_layers |
Retrieve information about all available GIBS image layers and their capabilities |
get_image_analyze |
Load and analyze images from URLs with automatic processing and base64 conversion for LLM analysis |
Features
- Astronomy Picture of the Day (APOD) with daily astronomical images and descriptions
- Mars rover images with various camera options and date filtering
- Near-Earth object (NEO) data with asteroid and approach information
- Earth imagery (EPIC) from NASA's DSCOVR satellite
- GIBS satellite imagery with high-quality Earth snapshots
- GIBS layer information for available satellite data sets
- Image analysis tool with automatic format detection, compression, and base64 conversion
- Comprehensive error handling for API timeouts and invalid parameters
Environment Variables
Required
NASA_API_KEY- NASA API key for accessing public NASA APIs
Usage Examples
Get today's astronomy picture
Show me Mars rover images from January 15, 2024
Find asteroids approaching Earth in the next 7 days
Get satellite images of the USA
Show me enhanced color Earth images
Notes
Requires Python 3.8+ and a free NASA API key from https://api.nasa.gov/. The image analysis tool returns imagecontent format, which is currently supported only in Claude 4. The maximum date range for NEO data is 7 days according to NASA API limitations.