Carbon Intensity UK

Science API · Works in United Kingdom · National Grid data · No API key

TL;DR

The Carbon Intensity API from the National Grid ESO provides real-time and forecast data on the carbon intensity of electricity generation in the UK. It returns the current carbon footprint (in gCO2/kWh) of the national grid, broken down by fuel type (gas, coal, wind, solar, nuclear, etc.). The API also provides 48-hour forecasts and regional data for 13 UK regions. No authentication needed. Essential for building energy-aware applications that can schedule tasks when the grid is greenest.

Quick start: https://api.carbonintensity.org.uk/intensity/date

No API key needed — just make a request!

How to Use This API

1. Current Carbon Intensity

https://api.carbonintensity.org.uk/intensity

2. Today's Intensity (Half-Hourly Data)

https://api.carbonintensity.org.uk/intensity/date

3. 48-Hour Forecast

https://api.carbonintensity.org.uk/intensity/2026-06-15/2026-06-17

4. JavaScript — Get Current Carbon Level

fetch('https://api.carbonintensity.org.uk/intensity')
  .then(r => r.json())
  .then(data => {
    const now = data.data[0];
    console.log(`Current intensity: ${now.intensity.actual} gCO2/kWh`);
    console.log(`Classification: ${now.intensity.classification}`);
    // Classifications: very low, low, moderate, high, very high
  });

5. Python — Find Optimal Charging Time

import requests
from datetime import datetime, timedelta

start = datetime.now().strftime('%Y-%m-%dT%H:%MZ')
end = (datetime.now() + timedelta(hours=24)).strftime('%Y-%m-%dT%H:%MZ')

data = requests.get(
    f'https://api.carbonintensity.org.uk/intensity/{start}/{end}'
).json()

# Find the lowest intensity period
periods = data['data']
best = min(periods, key=lambda p: p['intensity']['forecast'])
print(f"Best time to charge: {best['from']}")
print(f"Forecast intensity: {best['intensity']['forecast']} gCO2/kWh")
Today's intensity: https://api.carbonintensity.org.uk/intensity/date

Frequently Asked Questions

What do the intensity classifications mean?
Classification levels: very low (0-50 gCO2/kWh), low (50-150), moderate (150-250), high (250-350), and very high (350+).
Can I get data by UK region?
Yes. Use /regional endpoints like https://api.carbonintensity.org.uk/regional for current regional data. There are 13 regions including North Scotland, South Wales, London, and more.
How often is the data updated?
Carbon intensity data is updated every 30 minutes, reflecting actual grid conditions. Forecast data is updated every 2 hours for the 48-hour outlook.
What fuel mix data is available?
The generation mix endpoint (/generation) breaks down electricity generation by fuel type: gas, coal, nuclear, wind, solar, hydro, biomass, French interconnector, and Dutch interconnector.
What date format does the API use?
Dates use ISO 8601 format: YYYY-MM-DD for dates and YYYY-MM-DDTHH:MMZ for date-time range queries. All times are in UTC.
Is the API free for commercial use?
Yes, the Carbon Intensity API is provided by National Grid ESO as open data. Free for any use including commercial applications.

API Details

API URL
https://api.carbonintensity.org.uk
Documentation
carbonintensity.org.uk
Category
Science
Authentication
Not Required
Geographic Coverage
United Kingdom (UK) — National Grid and 13 regions

What You Can Build