# eia-energy-mcp-server

eia-energy-mcp-server is an MCP server for Claude Code that provides access to EIA data on electricity, petroleum, natural gas, coal, and forecasts via MCP.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · 1457 installs · ★ 3 repo stars
- Author: cyanheads
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/cyanheads/eia-energy-mcp-server
- Updated: 2026-10-23
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/mcp/eia-energy-mcp-server

## What it does

The server exposes seven tools for EIA API v2. Four core tools — `eia_browse_routes` (category and dataset listing), `eia_describe_route` (leaf route structure with facets and date range), `eia_search_routes` (series name and filter value lookup), `eia_query_route` (time series retrieval with facet filters). Three DataCanvas tools — `eia_dataframe_describe`, `eia_dataframe_query`, `eia_dataframe_drop` — work only when DataCanvas is enabled; it is on by default, but the Claude Desktop bundle disables it via `CANVAS_PROVIDER_TYPE=none`.

You need an EIA API key, passed in the `EIA_API_KEY` environment variable. The server runs over STDIO or HTTP; a public host is up at `https://eia-energy-mcp-server--cyanheads.run.tools`. Request timeout is 56 seconds, enough for retries with exponential backoff.

Tools distinguish failure types: `rate_limited` for quota exceeded, `upstream_unreachable` for connection drops, `upstream_timeout` when EIA does not respond. If a facet holds thousands of values (plant IDs, mine IDs), the `values_query` parameter filters them by substring in `id`, `name` or `alias` — for `plantCode`, a `palo verde` query returns two plants in one call.

## Requirements
- Remote server: `https://eia-energy-mcp-server--cyanheads.run.tools`

## Install

### Claude Code (native platform)

**Platform CLI: remote server**
```bash
claude mcp add --transport http eia-energy-mcp-server https://eia-energy-mcp-server--cyanheads.run.tools
```

### Codex

**Platform CLI: remote server**
```bash
codex mcp add eia-energy-mcp-server --url https://eia-energy-mcp-server--cyanheads.run.tools
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "eia-energy-mcp-server": {
            "url": "https://eia-energy-mcp-server--cyanheads.run.tools"
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "eia-energy-mcp-server": {
            "type": "http",
            "url": "https://eia-energy-mcp-server--cyanheads.run.tools"
        }
    }
}
```

### Gemini CLI

**Platform CLI: remote server**
```bash
gemini mcp add -t http eia-energy-mcp-server https://eia-energy-mcp-server--cyanheads.run.tools
```

## When to use it
- Find a time series by legacy APIv1 series ID or plain-language name
- Retrieve oil price or Henry Hub spot data with facet filters
- Run SQL queries across multiple loaded EIA datasets
- Inspect dataset structure: facets, frequencies, date coverage
- Filter thousands of facet values by substring match

## Example prompts
- Find the Henry Hub spot price series in EIA and show data for the past year
- Load electricity generation data from `electricity/facility-fuel` for Palo Verde plant
- Run SQL: `SELECT period, value FROM df_electricity WHERE fuelTypeDescription = 'Coal'`

## Similar
- [DC Hub: Data Center, Colocation, Power Grid & Energy Intelligence](https://affpapa.org/en/nevibecode/mcp/dc-hub-data-center-colocation-power-grid-energy-intelligence.md) — MCP server · 3573 installs
- [EnergyAI: Solar and Clean-Energy Incentives](https://affpapa.org/en/nevibecode/mcp/energyai-solar-and-clean-energy-incentives.md) — MCP server · 1161 installs
- [energy-expert](https://affpapa.org/en/nevibecode/skills/energy-expert.md) — skill · 282 installs
- [ha-energy](https://affpapa.org/en/nevibecode/skills/ha-energy.md) — skill · 110 installs
- [energy-systems](https://affpapa.org/en/nevibecode/skills/energy-systems.md) — skill · 1 install
- [energy-procurement](https://affpapa.org/en/nevibecode/skills/energy-procurement.md) — skill · ★ 50109 repo stars

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
