Energy API Reference
Ofgem energy price-cap rates for standard variable tariffs in Great Britain.
Base URL: https://api.govdata.dev/v1
Energy price cap
Returns every regional unit rate and standing charge for the current or requested Ofgem cap period, for tariff-comparison services, budgeting tools, and consumer-support teams. Estimate a household's capped variable-tariff cost from its actual kWh usage or compare payment methods across Great Britain's 14 electricity distribution regions.
/v1/energy/price-cap
Waiting for request...
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
period |
string | No | current period | A cap-period start date in YYYY-MM-DD format, or history to return every loaded period. |
curl -H "Authorization: Bearer YOUR_API_KEY" \ "https://api.govdata.dev/v1/energy/price-cap?period=2026-07-01"
uri = URI("https://api.govdata.dev/v1/energy/price-cap?period=2026-07-01") req = Net::HTTP::Get.new(uri, "Authorization" => "Bearer YOUR_API_KEY") res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |http| http.request(req) }
response = requests.get( "https://api.govdata.dev/v1/energy/price-cap", headers={"Authorization": "Bearer YOUR_API_KEY"}, params={"period": "2026-07-01"} )
const url = new URL("https://api.govdata.dev/v1/energy/price-cap"); url.searchParams.set("period", "2026-07-01"); const response = await fetch(url, { headers: { Authorization: "Bearer YOUR_API_KEY" } });
Response
{ "data": { "period": { "start": "2026-07-01", "end": "2026-09-30", "typical_annual_bill_gbp": 1663 }, "rates": [ { "fuel": "electricity", "payment_method": "direct_debit", "region": "Eastern", "unit_rate_pence_per_kwh": "26.38", "standing_charge_pence_per_day": "53.94" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "East Midlands", "unit_rate_pence_per_kwh": "25.10", "standing_charge_pence_per_day": "53.60" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "London", "unit_rate_pence_per_kwh": "26.35", "standing_charge_pence_per_day": "44.78" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "Northern", "unit_rate_pence_per_kwh": "25.22", "standing_charge_pence_per_day": "64.29" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "26.42", "standing_charge_pence_per_day": "57.55" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "27.66", "standing_charge_pence_per_day": "70.76" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "North West", "unit_rate_pence_per_kwh": "26.13", "standing_charge_pence_per_day": "47.61" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "South East", "unit_rate_pence_per_kwh": "26.67", "standing_charge_pence_per_day": "54.45" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "Southern", "unit_rate_pence_per_kwh": "26.42", "standing_charge_pence_per_day": "49.70" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "25.85", "standing_charge_pence_per_day": "64.17" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "South Wales", "unit_rate_pence_per_kwh": "26.33", "standing_charge_pence_per_day": "57.84" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "South West", "unit_rate_pence_per_kwh": "26.39", "standing_charge_pence_per_day": "57.89" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "West Midlands", "unit_rate_pence_per_kwh": "25.33", "standing_charge_pence_per_day": "59.71" }, { "fuel": "electricity", "payment_method": "direct_debit", "region": "Yorkshire", "unit_rate_pence_per_kwh": "25.31", "standing_charge_pence_per_day": "64.38" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Eastern", "unit_rate_pence_per_kwh": "7.26", "standing_charge_pence_per_day": "28.70" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "East Midlands", "unit_rate_pence_per_kwh": "7.19", "standing_charge_pence_per_day": "28.78" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "London", "unit_rate_pence_per_kwh": "7.50", "standing_charge_pence_per_day": "29.52" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Northern", "unit_rate_pence_per_kwh": "7.28", "standing_charge_pence_per_day": "29.15" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "7.23", "standing_charge_pence_per_day": "29.22" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "7.28", "standing_charge_pence_per_day": "29.42" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "North West", "unit_rate_pence_per_kwh": "7.24", "standing_charge_pence_per_day": "29.17" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "South East", "unit_rate_pence_per_kwh": "7.39", "standing_charge_pence_per_day": "28.63" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Southern", "unit_rate_pence_per_kwh": "7.53", "standing_charge_pence_per_day": "28.53" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "7.23", "standing_charge_pence_per_day": "29.24" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "South Wales", "unit_rate_pence_per_kwh": "7.42", "standing_charge_pence_per_day": "29.30" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "South West", "unit_rate_pence_per_kwh": "7.48", "standing_charge_pence_per_day": "28.68" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "West Midlands", "unit_rate_pence_per_kwh": "7.27", "standing_charge_pence_per_day": "29.06" }, { "fuel": "gas", "payment_method": "direct_debit", "region": "Yorkshire", "unit_rate_pence_per_kwh": "7.27", "standing_charge_pence_per_day": "29.12" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Eastern", "unit_rate_pence_per_kwh": "25.58", "standing_charge_pence_per_day": "53.94" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "East Midlands", "unit_rate_pence_per_kwh": "24.34", "standing_charge_pence_per_day": "53.60" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "London", "unit_rate_pence_per_kwh": "25.55", "standing_charge_pence_per_day": "44.78" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Northern", "unit_rate_pence_per_kwh": "24.46", "standing_charge_pence_per_day": "64.29" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "25.62", "standing_charge_pence_per_day": "57.55" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "26.82", "standing_charge_pence_per_day": "70.76" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "North West", "unit_rate_pence_per_kwh": "25.34", "standing_charge_pence_per_day": "47.61" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "South East", "unit_rate_pence_per_kwh": "25.86", "standing_charge_pence_per_day": "54.45" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Southern", "unit_rate_pence_per_kwh": "25.62", "standing_charge_pence_per_day": "49.70" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "25.07", "standing_charge_pence_per_day": "64.17" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "South Wales", "unit_rate_pence_per_kwh": "25.54", "standing_charge_pence_per_day": "57.84" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "South West", "unit_rate_pence_per_kwh": "25.59", "standing_charge_pence_per_day": "57.89" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "West Midlands", "unit_rate_pence_per_kwh": "24.57", "standing_charge_pence_per_day": "59.71" }, { "fuel": "electricity", "payment_method": "prepayment", "region": "Yorkshire", "unit_rate_pence_per_kwh": "24.54", "standing_charge_pence_per_day": "64.38" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Eastern", "unit_rate_pence_per_kwh": "7.06", "standing_charge_pence_per_day": "28.70" }, { "fuel": "gas", "payment_method": "prepayment", "region": "East Midlands", "unit_rate_pence_per_kwh": "6.92", "standing_charge_pence_per_day": "28.78" }, { "fuel": "gas", "payment_method": "prepayment", "region": "London", "unit_rate_pence_per_kwh": "7.27", "standing_charge_pence_per_day": "29.52" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Northern", "unit_rate_pence_per_kwh": "7.06", "standing_charge_pence_per_day": "29.15" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "6.95", "standing_charge_pence_per_day": "29.22" }, { "fuel": "gas", "payment_method": "prepayment", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "6.99", "standing_charge_pence_per_day": "29.42" }, { "fuel": "gas", "payment_method": "prepayment", "region": "North West", "unit_rate_pence_per_kwh": "6.95", "standing_charge_pence_per_day": "29.17" }, { "fuel": "gas", "payment_method": "prepayment", "region": "South East", "unit_rate_pence_per_kwh": "7.14", "standing_charge_pence_per_day": "28.63" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Southern", "unit_rate_pence_per_kwh": "7.32", "standing_charge_pence_per_day": "28.53" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "6.95", "standing_charge_pence_per_day": "29.24" }, { "fuel": "gas", "payment_method": "prepayment", "region": "South Wales", "unit_rate_pence_per_kwh": "7.15", "standing_charge_pence_per_day": "29.30" }, { "fuel": "gas", "payment_method": "prepayment", "region": "South West", "unit_rate_pence_per_kwh": "7.27", "standing_charge_pence_per_day": "28.68" }, { "fuel": "gas", "payment_method": "prepayment", "region": "West Midlands", "unit_rate_pence_per_kwh": "7.01", "standing_charge_pence_per_day": "29.06" }, { "fuel": "gas", "payment_method": "prepayment", "region": "Yorkshire", "unit_rate_pence_per_kwh": "7.01", "standing_charge_pence_per_day": "29.12" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Eastern", "unit_rate_pence_per_kwh": "27.85", "standing_charge_pence_per_day": "62.74" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "East Midlands", "unit_rate_pence_per_kwh": "26.49", "standing_charge_pence_per_day": "62.13" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "London", "unit_rate_pence_per_kwh": "27.81", "standing_charge_pence_per_day": "52.13" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Northern", "unit_rate_pence_per_kwh": "26.63", "standing_charge_pence_per_day": "73.22" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "27.89", "standing_charge_pence_per_day": "65.92" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "29.20", "standing_charge_pence_per_day": "79.63" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "North West", "unit_rate_pence_per_kwh": "27.58", "standing_charge_pence_per_day": "55.51" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "South East", "unit_rate_pence_per_kwh": "28.15", "standing_charge_pence_per_day": "63.33" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Southern", "unit_rate_pence_per_kwh": "27.89", "standing_charge_pence_per_day": "58.32" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "27.29", "standing_charge_pence_per_day": "72.78" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "South Wales", "unit_rate_pence_per_kwh": "27.80", "standing_charge_pence_per_day": "66.20" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "South West", "unit_rate_pence_per_kwh": "27.86", "standing_charge_pence_per_day": "66.86" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "West Midlands", "unit_rate_pence_per_kwh": "26.74", "standing_charge_pence_per_day": "68.37" }, { "fuel": "electricity", "payment_method": "standard_credit", "region": "Yorkshire", "unit_rate_pence_per_kwh": "26.72", "standing_charge_pence_per_day": "73.28" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Eastern", "unit_rate_pence_per_kwh": "7.64", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "East Midlands", "unit_rate_pence_per_kwh": "7.57", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "London", "unit_rate_pence_per_kwh": "7.90", "standing_charge_pence_per_day": "36.68" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Northern", "unit_rate_pence_per_kwh": "7.67", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Northern Scotland", "unit_rate_pence_per_kwh": "7.61", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "North Wales and Mersey", "unit_rate_pence_per_kwh": "7.66", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "North West", "unit_rate_pence_per_kwh": "7.62", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "South East", "unit_rate_pence_per_kwh": "7.78", "standing_charge_pence_per_day": "36.69" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Southern", "unit_rate_pence_per_kwh": "7.92", "standing_charge_pence_per_day": "36.68" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Southern Scotland", "unit_rate_pence_per_kwh": "7.61", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "South Wales", "unit_rate_pence_per_kwh": "7.82", "standing_charge_pence_per_day": "36.69" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "South West", "unit_rate_pence_per_kwh": "7.87", "standing_charge_pence_per_day": "36.68" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "West Midlands", "unit_rate_pence_per_kwh": "7.66", "standing_charge_pence_per_day": "36.70" }, { "fuel": "gas", "payment_method": "standard_credit", "region": "Yorkshire", "unit_rate_pence_per_kwh": "7.65", "standing_charge_pence_per_day": "36.70" } ], "notes": { "coverage": "Standard variable tariffs in Great Britain", "cap_scope": "Maximum unit rates and standing charges; not a cap on the total bill", "regional_variation": "Rates vary across Ofgem's 14 electricity distribution regions" } }, "meta": { "api_version": "v1", "licence": "Open Government Licence v3.0", "source": "Ofgem", "source_url": "https://www.ofgem.gov.uk/information-consumers/energy-advice-households/energy-price-cap-unit-rates-and-standing-charges" } }
unit_rate_pence_per_kwh and standing_charge_pence_per_day are capped per-unit prices, returned as two-decimal strings to preserve display precision. typical_annual_bill_gbp is Ofgem's national illustration at typical consumption, not the sum of the regional rows and not a household bill cap.
Error responses
400 — invalid period syntax.
{"error":{"code":"invalid_parameter","message":"period must be history or a cap-period start date in YYYY-MM-DD format.","documentation_url":"https://docs.govdata.dev/errors/invalid_parameter"}}
404 — valid date with no loaded cap period. There is no endpoint-specific 422 branch.
{"error":{"code":"not_found","message":"No energy price cap data is available for that period.","documentation_url":"https://docs.govdata.dev/errors/not_found"}}
Energy consumption
Returns DESNZ annual electricity and weather-corrected gas meter counts and consumption for Great Britain local authorities. Use it to compare local demand, track changes over time, or provide context for decarbonisation plans.
/v1/energy/consumption
Waiting for request...
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
fuel |
string | No | all | electricity or gas. |
from_year |
integer | No | earliest | Inclusive first year. |
to_year |
integer | No | latest | Inclusive last year. |
geography_code |
string | No | all | Exact LA code. |
geography_name |
string | No | all | Case-insensitive LA-name prefix. |
level |
string | No | all | Currently la. |
page |
integer | No | 1 | Page number. |
per_page |
integer | No | 25 | Rows per page, maximum 100. |
curl -H "Authorization: Bearer YOUR_API_KEY" "https://api.govdata.dev/v1/energy/consumption?fuel=electricity&geography_code=E08000025&from_year=2024"
URI.open("https://api.govdata.dev/v1/energy/consumption?fuel=electricity&geography_code=E08000025", "Authorization" => "Bearer YOUR_API_KEY")
requests.get("https://api.govdata.dev/v1/energy/consumption", params={"fuel":"electricity","geography_code":"E08000025"}, headers={"Authorization":"Bearer YOUR_API_KEY"})
await fetch("https://api.govdata.dev/v1/energy/consumption?fuel=electricity&geography_code=E08000025", {headers:{Authorization:"Bearer YOUR_API_KEY"}});
Response
{"data":[{"fuel":"electricity","year":2024,"geography":{"level":"la","code":"E08000025","name":"Birmingham"},"meters_count":482582,"total_consumption_kwh":3743422722.316,"mean_consumption_kwh":7757.071,"median_consumption_kwh":2668.5}],"meta":{"source":"Department for Energy Security and Net Zero","units":{"consumption":"kWh","meters_count":"meters"}},"pagination":{"total":1,"page":1,"per_page":25,"total_pages":1}}
Workbook meter counts (thousands) and totals (GWh) are normalised to whole meters and kWh; published mean and median values are already kWh per meter. Empty filter results are a successful empty page, so endpoint-specific 404/422 errors do not apply; malformed authentication uses the shared 400/401 error shapes.
Fuel poverty
Returns England LSOA household estimates under the Low Income Low Energy Efficiency (LILEE) metric, for targeting support and describing broad spatial patterns. DESNZ cautions against fine ranking or year-on-year LSOA comparisons.
/v1/energy/fuel-poverty
Waiting for request...
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
year |
integer | No | all | Data year. |
lsoa |
string | No | all | Exact LSOA code. |
la |
string | No | all | Exact local-authority code. |
page |
integer | No | 1 | Page number. |
per_page |
integer | No | 25 | Rows per page, maximum 100. |
curl -H "Authorization: Bearer YOUR_API_KEY" "https://api.govdata.dev/v1/energy/fuel-poverty?year=2024&la=E09000001"
URI.open("https://api.govdata.dev/v1/energy/fuel-poverty?year=2024&la=E09000001", "Authorization" => "Bearer YOUR_API_KEY")
requests.get("https://api.govdata.dev/v1/energy/fuel-poverty", params={"year":2024,"la":"E09000001"}, headers={"Authorization":"Bearer YOUR_API_KEY"})
await fetch("https://api.govdata.dev/v1/energy/fuel-poverty?year=2024&la=E09000001", {headers:{Authorization:"Bearer YOUR_API_KEY"}});
Response
{"data":[{"year":2024,"lsoa":{"code":"E01000001","name":"City of London 001A"},"local_authority":{"code":"E09000001","name":"City of London"},"households":918,"fuel_poor_households":42,"proportion":4.575163}],"meta":{"metric":"Low Income Low Energy Efficiency (LILEE)","units":{"proportion":"percent (0 to 100)"}},"pagination":{"total":1,"page":1,"per_page":25,"total_pages":1}}
proportion preserves the workbook's percentage scale (0–100), not a 0–1 ratio. Empty filter results return an empty page; endpoint-specific 404/422 branches do not apply.
Data notes
Coverage and cadence: standard variable (default) tariffs in England, Scotland and Wales. Each announced period is verified against Ofgem's published cap model and added manually; a weekly drift check flags discrepancies. Northern Ireland has a separate energy market and is not covered.
Licence and attribution: source Ofgem default tariff cap levels, reused under the Open Government Licence v3.0. Attribute Ofgem when republishing.
The cap limits unit rates and standing charges; it is not a cap on your total bill. Bills still depend on consumption. Rates vary by payment method and across 14 electricity distribution regions; the endpoint contains single-rate electricity only, not Economy 7 or other multi-rate tariffs.
The £1,663 headline for 1 July–30 September 2026 uses Ofgem's revised Typical Domestic Consumption Values announced on 27 May 2026. It is illustrative, not guaranteed. The canonical cap model is XLSX; current and immediately preceding periods are verified in seeds, while historical coverage before April 2026 is not yet loaded.
DESNZ coverage: LA electricity and weather-corrected gas series cover 2013–2024 and are revised annually in December. Consumption is Great Britain only. Fuel poverty covers England LSOAs for data year 2024 using LILEE and is released annually. Both sources are reused under the Open Government Licence v3.0.