U.S. Energy Information Administration logo
Skip to sub-navigation

OPEN DATA

Committed to making energy data more accessible, understandable,
relevant, and responsive to your needs.

Notice: EIA will discontinue support for its legacy API (APIv1) in November, 2022. Excel add-in v1 sheets will continue to function as they are. Please refer to our documentation for the APIv2 interaction methods and our APIv2 query browser to view the data.

EIA Chart Widget

HTML for the embedded visualization

Copy and paste the following HTML into your web page:
<iframe id="eia_widget" style="width: 100%; height: 500px;" src="//www.eia.gov/opendata/v1/embed/iframe.php?api_key=YOUR_KEY_HERE&series_id=PET.RWTC.D" load="iframe_load"></iframe>

Note modify the width and height style to size the visualization on your web page.

Visualization preview

Modify visualization settings:

  1. Pie charts degrade to bar charts when data is missing or when relationship is not additive.
  2. Area charts degrade to line charts when data is missing or when relationship is not additive.
(semi-colon separated list)
Note: Defining an end date means the embedded visualization will be a snapshot and will not show new data when released by EIA.

Licenses and Source Code

The visualization makes use of an EIA visualization JavaScript library, several free open source JavaScript libraries, a commercial open source JavaScript library, and EIA's data service. When embedding a visualization via the above code (an IFRAME to an eia.gov hosted web page), your use of these libraries is covered by EIA's licenses.

The EIA visualization libary's source code is available on github.com/eiagov. Users are invited to fork the code and submit improvements and new features.

Statistics
Analysis
Tools
Education
News

Petroleum & Other Liquids

Crude oil, gasoline, heating oil, diesel, propane, and other liquids including biofuels and natural gas liquids.

Natural Gas

Exploration and reserves, storage, imports and exports, production, prices, sales.

Electricity

Sales, revenue and prices, power plants, fuel use, stocks, generation, trade, demand & emissions.

Coal

Reserves, production, prices, employment and productivity, distribution, stocks, imports and exports.

Nuclear & Uranium

Uranium fuel, nuclear reactors, generation, spent fuel.

Renewable & Alternative Fuels

Includes hydropower, solar, wind, geothermal, biomass and ethanol.

EIA Survey Forms

Forms EIA uses to collect energy data including descriptions, links to survey instructions, and additional information.

Total Energy

Comprehensive data summaries, comparisons, analysis, and projections integrated across all energy sources.

U.S. States

State energy information, including overviews, rankings, data, and analyses.

International

International energy information, including overviews, rankings, data, and analyses.

Environment

Greenhouse gas data, voluntary reporting, electric power plant emissions.

Data Tools, Apps, & Maps

Tools to customize searches, view specific data sets, study detailed documentation, and access time-series data.

Open Data

EIA's free and open data available as API, Excel add-in, bulk files, and widgets

EIA Beta

Come test out some of the products still in development and let us know what you think!

Open Source Code

EIA's open source code, available on GitHub.

RSS Feeds

Subscribe to feeds for updates on EIA products including Today in Energy and What's New.