What is Grid Status?#

gridstatus logo

Tests Code Coverage PyPI Version

gridstatus is a standardized Python API to electricity supply, demand, and pricing data for the major Independent System Operators (ISOs) in the United States.

Currently gridstatus supports CAISO, SPP, ISONE, MISO, Ercot, NYISO, and PJM.

We’d love to answer any usage or data access questions! Please let us know by posting a GitHub issue.

5 Minute Overview#

First, we can see all of the ISOs that are supported

import gridstatus
gridstatus.list_isos()
Name Id Class
0 Midcontinent ISO miso MISO
1 California ISO caiso CAISO
2 PJM pjm PJM
3 Electric Reliability Council of Texas ercot Ercot
4 Southwest Power Pool spp SPP
5 New York ISO nyiso NYISO
6 ISO New England isone ISONE
7 Independent Electricity System Operator ieso IESO

Next, we can select an ISO we want to use

caiso = gridstatus.CAISO()

Fuel Mix#

All ISOs have the same API to methods like get_fuel_mix, get_load, and get_status, etc. Here is how we can get the fuel mix

caiso.get_fuel_mix("today")
Time Interval Start Interval End Solar Wind Geothermal Biomass Biogas Small Hydro Coal Nuclear Natural Gas Large Hydro Batteries Imports Other
0 2024-10-04 00:00:00-07:00 2024-10-04 00:00:00-07:00 2024-10-04 00:05:00-07:00 -20 2012 732 296 175 234 0 2218 13605 1845 -789 6965 0
1 2024-10-04 00:05:00-07:00 2024-10-04 00:05:00-07:00 2024-10-04 00:10:00-07:00 -19 2050 735 299 176 233 0 2218 13461 1777 138 6578 0
2 2024-10-04 00:10:00-07:00 2024-10-04 00:10:00-07:00 2024-10-04 00:15:00-07:00 -19 2077 748 296 176 234 0 2217 13275 1799 476 6435 0
3 2024-10-04 00:15:00-07:00 2024-10-04 00:15:00-07:00 2024-10-04 00:20:00-07:00 -21 2089 751 297 176 233 0 2217 13142 1806 621 6308 0
4 2024-10-04 00:20:00-07:00 2024-10-04 00:20:00-07:00 2024-10-04 00:25:00-07:00 -21 2094 736 297 176 233 0 2217 13008 1821 472 6469 0
... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
77 2024-10-04 06:25:00-07:00 2024-10-04 06:25:00-07:00 2024-10-04 06:30:00-07:00 -22 1195 747 308 175 222 0 2216 12359 1557 963 6373 0
78 2024-10-04 06:30:00-07:00 2024-10-04 06:30:00-07:00 2024-10-04 06:35:00-07:00 -22 1163 739 312 175 222 0 2216 12358 1561 933 6536 0
79 2024-10-04 06:35:00-07:00 2024-10-04 06:35:00-07:00 2024-10-04 06:40:00-07:00 -19 1120 737 311 175 221 0 2217 12401 1542 944 6646 0
80 2024-10-04 06:40:00-07:00 2024-10-04 06:40:00-07:00 2024-10-04 06:45:00-07:00 -10 1093 741 307 175 221 0 2217 12455 1549 1067 6619 0
81 2024-10-04 06:45:00-07:00 2024-10-04 06:45:00-07:00 2024-10-04 06:50:00-07:00 5 1062 740 308 176 221 0 2217 12440 1557 1117 6658 0

82 rows × 16 columns

Load#

or the energy demand throughout the current day as a Pandas DataFrame

caiso.get_load("today")
Time Interval Start Interval End Load
0 2024-10-04 00:00:00-07:00 2024-10-04 00:00:00-07:00 2024-10-04 00:05:00-07:00 26711.0
1 2024-10-04 00:05:00-07:00 2024-10-04 00:05:00-07:00 2024-10-04 00:10:00-07:00 26844.0
2 2024-10-04 00:10:00-07:00 2024-10-04 00:10:00-07:00 2024-10-04 00:15:00-07:00 27119.0
3 2024-10-04 00:15:00-07:00 2024-10-04 00:15:00-07:00 2024-10-04 00:20:00-07:00 27017.0
4 2024-10-04 00:20:00-07:00 2024-10-04 00:20:00-07:00 2024-10-04 00:25:00-07:00 26871.0
... ... ... ... ...
77 2024-10-04 06:25:00-07:00 2024-10-04 06:25:00-07:00 2024-10-04 06:30:00-07:00 25728.0
78 2024-10-04 06:30:00-07:00 2024-10-04 06:30:00-07:00 2024-10-04 06:35:00-07:00 25856.0
79 2024-10-04 06:35:00-07:00 2024-10-04 06:35:00-07:00 2024-10-04 06:40:00-07:00 25987.0
80 2024-10-04 06:40:00-07:00 2024-10-04 06:40:00-07:00 2024-10-04 06:45:00-07:00 26149.0
81 2024-10-04 06:45:00-07:00 2024-10-04 06:45:00-07:00 2024-10-04 06:50:00-07:00 26200.0

82 rows × 4 columns

Load Forecast#

Another dataset we can query is the load forecast

nyiso = gridstatus.NYISO()
nyiso.get_load_forecast("today")
/home/docs/checkouts/readthedocs.org/user_builds/isodata/checkouts/stable/gridstatus/nyiso.py:906: FutureWarning: Parsed string "10/03/24 07:10 EDT" included an un-recognized timezone "EDT". Dropping unrecognized timezones is deprecated; in a future version this will raise. Instead pass the string without the timezone, then use .tz_localize to convert to a recognized timezone.
  return pd.Timestamp(last_updated_date, tz=self.default_timezone)
Time Interval Start Interval End Forecast Time Load Forecast
0 2024-10-04 00:00:00-04:00 2024-10-04 00:00:00-04:00 2024-10-04 01:00:00-04:00 2024-10-03 07:10:00-04:00 13512
1 2024-10-04 01:00:00-04:00 2024-10-04 01:00:00-04:00 2024-10-04 02:00:00-04:00 2024-10-03 07:10:00-04:00 13011
2 2024-10-04 02:00:00-04:00 2024-10-04 02:00:00-04:00 2024-10-04 03:00:00-04:00 2024-10-03 07:10:00-04:00 12682
3 2024-10-04 03:00:00-04:00 2024-10-04 03:00:00-04:00 2024-10-04 04:00:00-04:00 2024-10-03 07:10:00-04:00 12499
4 2024-10-04 04:00:00-04:00 2024-10-04 04:00:00-04:00 2024-10-04 05:00:00-04:00 2024-10-03 07:10:00-04:00 12625
... ... ... ... ... ...
139 2024-10-09 19:00:00-04:00 2024-10-09 19:00:00-04:00 2024-10-09 20:00:00-04:00 2024-10-03 07:10:00-04:00 16731
140 2024-10-09 20:00:00-04:00 2024-10-09 20:00:00-04:00 2024-10-09 21:00:00-04:00 2024-10-03 07:10:00-04:00 16326
141 2024-10-09 21:00:00-04:00 2024-10-09 21:00:00-04:00 2024-10-09 22:00:00-04:00 2024-10-03 07:10:00-04:00 15682
142 2024-10-09 22:00:00-04:00 2024-10-09 22:00:00-04:00 2024-10-09 23:00:00-04:00 2024-10-03 07:10:00-04:00 14766
143 2024-10-09 23:00:00-04:00 2024-10-09 23:00:00-04:00 2024-10-10 00:00:00-04:00 2024-10-03 07:10:00-04:00 13881

144 rows × 5 columns

Historical Data#

When supported, you can use the historical method calls to get data for a specific day in the past. For example,

caiso.get_load("Jan 1, 2020")
Time Interval Start Interval End Load
0 2020-01-01 00:00:00-08:00 2020-01-01 00:00:00-08:00 2020-01-01 00:05:00-08:00 21533
1 2020-01-01 00:05:00-08:00 2020-01-01 00:05:00-08:00 2020-01-01 00:10:00-08:00 21429
2 2020-01-01 00:10:00-08:00 2020-01-01 00:10:00-08:00 2020-01-01 00:15:00-08:00 21320
3 2020-01-01 00:15:00-08:00 2020-01-01 00:15:00-08:00 2020-01-01 00:20:00-08:00 21272
4 2020-01-01 00:20:00-08:00 2020-01-01 00:20:00-08:00 2020-01-01 00:25:00-08:00 21193
... ... ... ... ...
283 2020-01-01 23:35:00-08:00 2020-01-01 23:35:00-08:00 2020-01-01 23:40:00-08:00 20494
284 2020-01-01 23:40:00-08:00 2020-01-01 23:40:00-08:00 2020-01-01 23:45:00-08:00 20383
285 2020-01-01 23:45:00-08:00 2020-01-01 23:45:00-08:00 2020-01-01 23:50:00-08:00 20297
286 2020-01-01 23:50:00-08:00 2020-01-01 23:50:00-08:00 2020-01-01 23:55:00-08:00 20242
287 2020-01-01 23:55:00-08:00 2020-01-01 23:55:00-08:00 2020-01-02 00:00:00-08:00 20128

288 rows × 4 columns

Frequently, we want to get data across multiple days. We can do that by providing a start and end parameter to any iso.get_* method

caiso_load = caiso.get_load(start="Jan 1, 2021", end="Feb 1, 2021")
caiso_load
Time Interval Start Interval End Load
0 2021-01-01 00:00:00-08:00 2021-01-01 00:00:00-08:00 2021-01-01 00:05:00-08:00 21937.0
1 2021-01-01 00:05:00-08:00 2021-01-01 00:05:00-08:00 2021-01-01 00:10:00-08:00 21858.0
2 2021-01-01 00:10:00-08:00 2021-01-01 00:10:00-08:00 2021-01-01 00:15:00-08:00 21827.0
3 2021-01-01 00:15:00-08:00 2021-01-01 00:15:00-08:00 2021-01-01 00:20:00-08:00 21757.0
4 2021-01-01 00:20:00-08:00 2021-01-01 00:20:00-08:00 2021-01-01 00:25:00-08:00 21664.0
... ... ... ... ...
8923 2021-01-31 23:35:00-08:00 2021-01-31 23:35:00-08:00 2021-01-31 23:40:00-08:00 20054.0
8924 2021-01-31 23:40:00-08:00 2021-01-31 23:40:00-08:00 2021-01-31 23:45:00-08:00 19952.0
8925 2021-01-31 23:45:00-08:00 2021-01-31 23:45:00-08:00 2021-01-31 23:50:00-08:00 19859.0
8926 2021-01-31 23:50:00-08:00 2021-01-31 23:50:00-08:00 2021-01-31 23:55:00-08:00 19763.0
8927 2021-01-31 23:55:00-08:00 2021-01-31 23:55:00-08:00 2021-02-01 00:00:00-08:00 19650.0

8928 rows × 4 columns

We can now see there is data for all of January 2021

import plotly.express as px

fig = px.line(caiso_load, x="Time", y="Load", title="CAISO Load - Jan '21")
fig