The project
What is UK Power?

UK Power is a personal project that pulls together live electricity information from across the UK into one place. It started as an outage map, aggregating fault reports from all seven Distribution Network Operators into a single view, and has grown to include live grid data: generation mix, carbon intensity, interconnector flows, and total demand.

The site is entirely unofficial and has no affiliation with any DNO, Ofgem, NESO, or any other industry body. All data is sourced from publicly available APIs and websites and is presented for personal interest and convenience only.

The person behind it
About Me

I graduated in the 1970s having studied subjects that would have qualified me for a B.Eng in either Electronic or Electrical Engineering. I chose a career in Electronics, but have always retained a keen interest in everything related to the generation and distribution of electrical power in the UK.

Watching the UK grid shift from coal-dominated generation toward renewables over the past decade or so has made the publicly available data increasingly compelling. This site is the result of wanting to explore that data in an accessible, visual form.

More about me at markhaworth.uk.

How it was built
A human and AI collaboration

UK Power is a collaboration between Mark's ideas, domain knowledge, and design direction, and Claude Code, an AI coding assistant made by Anthropic. Every line of code has been written by Claude; every decision about what to build, how it should look, and how it should behave has been Mark's.

The project is a good example of what this kind of pairing can produce: a fully functional, publicly accessible web service built iteratively through conversation, without Mark writing a single line of code himself.

🤖  Code by Claude Code (Anthropic). Concept, design and direction by Mark Haworth.
Technical detail
How it works

Outage data

Seven scrapers, one per Distribution Network Operator, run automatically every 10 minutes on a dedicated VPS. Each scraper fetches live outage data from the DNO's public website or API, normalises it into a common format, and writes it to a Supabase database. Outages that disappear from a DNO's feed are automatically marked as resolved and removed from the map after 24 hours. If a scraper fails three times in a row, an alert fires to the developer.

Grid data

Generation mix, carbon intensity, and regional data are fetched every 5 minutes from the Carbon Intensity API. Interconnector flows and total GB demand are fetched on the same schedule from the Elexon BMRS API. Both datasets are cached on the server, so all visitors share a single set of upstream API calls regardless of how many people are using the site at once. Browsers receive grid data from this site's own proxy endpoints rather than contacting the upstream APIs directly.

Infrastructure

The web server runs Node.js on Hostinger and deploys automatically whenever code is pushed to GitHub. Scrapers run on a separate VPS via cron jobs. The database is Supabase (managed PostgreSQL). The outage map uses Leaflet.js with OpenStreetMap tiles.

Credits and licensing
Data sources