Coronavirus in the UK API

Free to Use Varies (check documentation)

Overview

The Coronavirus in the UK API provides official UK Government data on Covid-19 cases, deaths, and vaccinations broken down by region and nation. It is free to use with no API key required, making it easy for beginners to access real government health data. Use it to build charts, monitor trends, or explore epidemiological data for England, Scotland, Wales, and Northern Ireland.

💡

Beginner Tip

The UKHSA dashboard API supports filtering by area type (nation, region, utla, ltla) and metric — start with a broad area_type=nation query to understand the data structure before drilling down to smaller regions.

Available Data

case counts and statistics
vaccination data
geographic breakdown
historical trend data

Example Response

JSON Response
{
  "url": "https://example.com",
  "safe": true,
  "threat_level": "none",
  "categories": [
    "clean"
  ],
  "scan_date": "2025-01-15T10:00:00Z"
}

Field Reference

count Total number of records available for the queried metric and geography.
results List of data points for the requested metric, each representing a date and value.
date Date of the data point in YYYY-MM-DD format.
metric_value The numeric value of the metric (e.g. number of cases or deaths) for that date.
geography The name of the geographic area the data applies to (e.g. England, London).

Implementation Example

const url = "https://coronavirus.data.gov.uk/details/developers-guide";
const response = await fetch(url);
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

404 Not Found The geography or metric name is misspelled or uses incorrect casing.
Browse the UKHSA dashboard website to find exact geography names and metric codes — they are case-sensitive.
Empty data array The date range or metric combination has no available data for the selected region.
Try a broader geography type like Nation before querying Lower Tier Local Authority (ltla) level data.
Slow response Requests for large date ranges with fine-grained geographic breakdowns return a lot of data.
Use the page_size parameter to limit results and paginate through data incrementally.

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 20/20
🔒 Security 15/15
🛠 Developer XP 15/20
✓ Reliability 7/15
Response Time 75ms

Fully tested on Apr 5, 2026

Technical Specifications

Auth No Auth
HTTPS REQUIRED
CORS UNKNOWN
Category Health
Difficulty Beginner
Verified: 2026-04-07

Similar APIs

View All →