API Directory › 🚀 Science & Space › USGS Earthquakes
No authHTTPSCORS

USGS Earthquakes API

Real-time and historical earthquake data from the US Geological Survey.

Auth
No auth needed
HTTPS
Yes
CORS
Yes
Open USGS Earthquakes docs ↗

What it does

The USGS Earthquake Catalog API serves real-time and historical earthquake data from the Advanced National Seismic System. Query by time window, magnitude, geographic box or radius, and depth; get back GeoJSON (also CSV, KML, plain text and QuakeML) that drops straight onto a map.

Base URL

https://earthquake.usgs.gov/fdsnws/event/1

Authentication

None. It’s a public US government service — no key, no account. Be a good citizen: request only the window you need and cache results.

Code examples

curl
curl "https://earthquake.usgs.gov/fdsnws/event/1/query?format=geojson&starttime=2026-01-01&minmagnitude=5&limit=5&orderby=time"
Python
import requests

r = requests.get(
    "https://earthquake.usgs.gov/fdsnws/event/1/query",
    params={
        "format": "geojson",
        "starttime": "2026-01-01",
        "minmagnitude": 5,
        "limit": 5,
        "orderby": "time",
    },
    timeout=15,
)
for f in r.json()["features"]:
    p = f["properties"]
    print(p["mag"], p["place"], p["time"])
JavaScript
const p = new URLSearchParams({
  format: "geojson", starttime: "2026-01-01",
  minmagnitude: "5", limit: "5", orderby: "time",
});
const res = await fetch(
  `https://earthquake.usgs.gov/fdsnws/event/1/query?${p}`
);
const { features } = await res.json();
features.forEach(f => console.log(f.properties.mag, f.properties.place));

Rate limits & quotas

No API key and no formal published rate limit, but a single query is capped at 20,000 events (use limit/offset or narrower time windows to paginate) and very large or very frequent requests may be throttled or return 429. For a live map, poll the pre-built summary feeds (/earthquakes/feed/v1.0/summary/) which are cached and cheap.

Key response fields

features[].properties.magMagnitude
features[].properties.placeHuman-readable location, e.g. “12km NE of Ridgecrest, CA”
features[].properties.timeOrigin time, Unix milliseconds UTC
features[].properties.tsunami1 if a tsunami event may be associated
features[].properties.urlUSGS event page
features[].geometry.coordinates[longitude, latitude, depth km]
metadata.countNumber of events returned

Common errors

400Bad parameter — e.g. starttime after endtime, or an unknown format.
404No events match (some clients surface this instead of an empty list).
429 / 503Too many requests or maintenance. Back off; prefer the cached summary feeds.

When to use it (and alternatives)

This is the authoritative source for earthquake data — use it directly for maps, alerts and research. For the simplest “recent quakes” widget, the static GeoJSON summary feeds are easier than the query endpoint. For global multi-hazard data (volcanoes, weather, floods) combine it with NASA EONET.

FAQ

Do I need an API key for USGS earthquake data?

No. The FDSN event service and the summary GeoJSON feeds are completely open.

How do I get only earthquakes near a specific point?

Use latitude, longitude and maxradiuskm (or a minlatitude/maxlatitude/minlongitude/maxlongitude box).

What timezone are the timestamps in?

All times are UTC. properties.time is Unix milliseconds; convert on the client.

New to APIs?

Short guides for working with this API — and any other.

🛠️ Handy LarzOS tools

Free tools to help you work with this API.

JSON Formatter

Related Science & Space APIs

← Back

More Science & Space APIs · All 196 APIs