Covid-19 API

⭐ Beginner's Pick Health / No Auth Required Beginner HTTPS CORS
Free to Use Varies (check documentation)

Overview

The Covid-19 API by M-Media Group provides daily case counts, deaths, and recoveries for every country in the world. It is free, open-source, and requires no API key, making it one of the easiest health APIs for beginners to use. It is a great resource for building global pandemic dashboards or learning to work with international health statistics.

💡

Beginner Tip

Use the /v1/ endpoint to get country-level totals, and add a country name or ISO code as a path parameter to filter results for a specific country — for example, /v1/countries/US returns US-only data.

Available Data

country name and code
population
capital city
region and subregion
flag image URL
case counts and statistics

Example Response

JSON Response
{
  "name": "Japan",
  "capital": "Tokyo",
  "population": 125800000,
  "region": "Asia",
  "languages": [
    "Japanese"
  ],
  "flag": "https://flagcdn.com/jp.svg",
  "currencies": [
    {
      "code": "JPY",
      "name": "Japanese yen"
    }
  ]
}

Field Reference

All Top-level object containing aggregated data for the country or worldwide.
confirmed Total confirmed Covid-19 cases for the country.
deaths Total number of Covid-19 related deaths.
recovered Total number of recoveries from Covid-19.
country Full name of the country the data corresponds to.
last_updated ISO 8601 timestamp of when the data was last refreshed.

Implementation Example

const url = "https://github.com/M-Media-Group/Covid-19-API";
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 or empty response for a country The country name may not match exactly what the API expects, or the ISO code is incorrect.
Try using the ISO 3166-1 alpha-2 country code (e.g. US, GB, FR) instead of the full country name for more reliable results.
Data appears outdated The API relies on publicly reported data which may lag a few days behind real-time figures.
Check the last_updated field in the response to confirm data freshness before displaying it to users.
CORS error in browser Browser requests may be blocked by cross-origin policy depending on the deployment environment.
Make API calls from a server-side backend or use a proxy to handle CORS when building web apps.

Matrix Score Breakdown

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

Fully tested on Apr 5, 2026

Technical Specifications

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

Similar APIs

View All →