Guide · Earthquakes and natural hazards in Chile
Chile earthquakes API: how to get the latest quake, its magnitude, depth and alerts as JSON
How to answer the usual questions about earthquakes in Chile from your code or an AI agent: what the latest one was, whether there was one today, which were the strongest this year, which happened near a city and which had a PAGER alert or a tsunami flag. With public-domain USGS data, in Chile time, using Better Llama's MCP tool and no key. Every response in this guide is a real call made on 24 November 2026.
Where does Chile's earthquake data come from?
There are two main sources:
- Centro Sismológico Nacional (CSN) of the Universidad de Chile, at sismologia.cl: Chile's official seismological source. Its data use page allows academic and outreach use with attribution; any other use needs the CSN's express written approval.
- U.S. Geological Survey (USGS), with its worldwide ComCat catalog and the public FDSN Event API, which includes Chile's earthquakes. Under its copyright policy, USGS data is public domain and credit to the source is requested.
The get_chile_earthquakes tool uses USGS data only. Its magnitudes and locations can differ from the CSN's, and the USGS catalog for Chile focuses on moderate earthquakes: the 9 earthquakes it returned for the last week were all magnitude 4.0 or more. If you need every minor tremor, the source is the CSN.
This is not an early warning or tsunami warning system. In an emergency, follow the official instructions of SENAPRED and SHOA.
Step by step: the latest earthquake with curl, Python and JavaScript
Step 1. Choose the question
With no arguments, the tool searches the last 7 days in mainland Chile and its coast, from magnitude 2.5, newest first, and returns up to 20 earthquakes. With maxItems set to 1 you get only the latest. The typical queries table shows the arguments for each question.
Step 2. Connect the MCP server
Use the MCP https://mcp.betterllama.com/mcp from your client (see how to connect your agent) or call it over HTTP with JSON-RPC, as below. No USGS key or sign-up is needed during the beta.
Step 3. Call the tool
The latest earthquake in Chile, with curl:
curl -s https://mcp.betterllama.com/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc": "2.0", "id": 1, "method": "tools/call", "params": {"name": "get_chile_earthquakes", "arguments": {"maxItems": 1}}}'Real response (2026-11-24 08:20 Chile time, content of result.content[0].text):
{
"tool": "get_chile_earthquakes",
"count": 1,
"results": [
{
"kind": "sismo",
"id": "us6000ucuj",
"timeUtc": "2026-11-22T21:47:32.112Z",
"timeChile": "2026-11-22T18:47:32-03:00",
"magnitude": 4.5,
"magnitudeType": "mb",
"place": "54 km NNE of Calama, Chile",
"latitude": -21.9972,
"longitude": -68.7311,
"depthKm": 123.268,
"inChile": true,
"tsunamiFlag": false,
"significance": 312,
"reviewStatus": "reviewed",
"eventType": "earthquake",
"network": "us",
"updatedUtc": "2026-11-22T22:28:31.040Z",
"url": "https://earthquake.usgs.gov/earthquakes/eventpage/us6000ucuj",
"source": "USGS",
"attribution": "Fuente: U.S. Geological Survey (USGS) Earthquake Hazards Program, ComCat — dominio público."
}
],
"warnings": [],
"stopReason": "maxItems",
"attribution": "Fuente: U.S. Geological Survey (USGS), Earthquake Hazards Program — dominio público.",
"source": "https://earthquake.usgs.gov/fdsnws/event/1/",
"retrievedAt": "2026-11-24T11:20:38.947Z"
}The 5 strongest earthquakes of the last year, in Python (pip install requests):
import json
import requests
URL = "https://mcp.betterllama.com/mcp"
HEADERS = {"Accept": "application/json, text/event-stream"}
def quakes(**arguments):
body = {"jsonrpc": "2.0", "id": 1, "method": "tools/call",
"params": {"name": "get_chile_earthquakes", "arguments": arguments}}
resp = requests.post(URL, json=body, headers=HEADERS, timeout=60)
resp.raise_for_status()
return json.loads(resp.json()["result"]["content"][0]["text"])
# The 5 strongest earthquakes in Chile over the last year (magnitude 5 or more)
data = quakes(fromDate="2025-11-24", toDate="2026-11-24", minMagnitude=5,
orderBy="magnitude", maxItems=5)
for q in data["results"]:
local = q["timeChile"][:16].replace("T", " ")
print(f'M{q["magnitude"]} {local} (Chile) {q["depthKm"]:.0f} km {q["place"]}')Real output:
M6.9 2026-05-25 17:52 (Chile) 109 km 34 km ENE of Calama, Chile
M6.2 2026-03-13 10:39 (Chile) 24 km 71 km W of Vallenar, Chile
M6.1 2026-02-12 10:34 (Chile) 46 km 28 km SW of Ovalle, Chile
M6 2026-05-31 17:34 (Chile) 25 km 33 km NW of Valparaíso, Chile
M5.7 2026-02-08 13:23 (Chile) 114 km 79 km ENE of La Tirana, ChileEarthquakes within 150 km of Santiago in the last month, in JavaScript. With region radio each earthquake has distanceKm:
// Earthquakes within 150 km of Santiago in the last month (Node 18+ or a browser)
const body = {
jsonrpc: "2.0", id: 1, method: "tools/call",
params: { name: "get_chile_earthquakes", arguments: {
region: "radio", latitude: -33.45, longitude: -70.66, radiusKm: 150,
fromDate: "2026-10-24", toDate: "2026-11-24" } },
};
const resp = await fetch("https://mcp.betterllama.com/mcp", {
method: "POST",
headers: { "Content-Type": "application/json", "Accept": "application/json, text/event-stream" },
body: JSON.stringify(body),
});
const data = JSON.parse((await resp.json()).result.content[0].text);
for (const q of data.results) {
console.log(`M${q.magnitude}, ${q.distanceKm} km from Santiago, ${q.timeChile}, ${q.place}`);
}Real output:
M4.2, 84.6 km from Santiago, 2026-10-28T09:52:12-03:00, 31 km SSW of Melipilla, Chile
M4.6, 141.4 km from Santiago, 2026-10-26T17:52:11-03:00, 18 km NNW of La Ligua, Chile
M4.2, 137.1 km from Santiago, 2026-10-25T21:55:58-03:00, 40 km W of Valparaíso, ChileStep 4. Use the result
magnitudeandmagnitudeType: the USGS magnitude and magnitude type (for examplembormww).depthKm,latitude,longitudeandplace: depth and location, withplaceas published by the USGS.timeUtcandtimeChile: the same time in UTC and in mainland Chile time, with its offset.alertLevel,tsunamiFlag,feltReports,cdiandmmi: PAGER alert, tsunami flag and intensity data, when the USGS has them.url,sourceandattribution: link to the event page and credit to the source, so you can cite it.stopReason:completedif everything came back,maxItemsif there is more and you cut it,noDataif there were no earthquakes.
Typical queries and their real results
Each row is a real call to get_chile_earthquakes made on 24 November 2026 between 08:20 and 08:22 Chile time.
| Question | Arguments | Real result (2026-11-24) |
|---|---|---|
| What was the latest earthquake? | {"maxItems": 1} | M4.5 at 123 km depth, 54 km NNE of Calama, Chile, 22 Nov 2026, 18:47 |
| Was there an earthquake today? | {"fromDate": "2026-11-24", "toDate": "2026-11-24", "minMagnitude": 2.5, "maxItems": 50} | 0 earthquakes at 08:20 on 24 November (stopReason noData) |
| Earthquakes in the last week | {"minMagnitude": 2.5, "maxItems": 200} | 9 earthquakes, from M4.0 to M5.1 |
| The strongest in the last year | {"fromDate": "2025-11-24", "toDate": "2026-11-24", "minMagnitude": 5, "orderBy": "magnitude", "maxItems": 10} | 10 earthquakes, led by M6.9 near Calama |
| Near Santiago (150 km, last month) | {"region": "radio", "latitude": -33.45, "longitude": -70.66, "radiusKm": 150, "fromDate": "2026-10-24", "toDate": "2026-11-24", "minMagnitude": 2.5, "maxItems": 50} | 3 earthquakes, the closest 84.6 km away |
| Shallow (≤ 30 km, M4+, last month) | {"fromDate": "2026-10-24", "toDate": "2026-11-24", "minMagnitude": 4, "maxDepthKm": 30, "maxItems": 50} | 11 of the month's 37 M4+ earthquakes |
| Yellow PAGER alert or higher (10 years) | {"fromDate": "2016-11-25", "toDate": "2026-11-24", "minAlertLevel": "yellow", "maxItems": 50} | 7 earthquakes, one with an orange alert |
| With a tsunami flag (10 years) | {"fromDate": "2016-11-25", "toDate": "2026-11-24", "tsunamiOnly": true, "maxItems": 50} | 11 earthquakes; 0 in the last year |
| Felt by people (last month) | {"fromDate": "2026-10-24", "toDate": "2026-11-24", "feltOnly": true, "maxItems": 50} | 10 earthquakes with “Did You Feel It?” reports |
| Including Easter Island (M4.5+, last month) | {"region": "chile_islas", "fromDate": "2026-10-24", "toDate": "2026-11-24", "minMagnitude": 4.5, "maxItems": 100} | 21 earthquakes, versus 15 for mainland Chile only |
About “was there an earthquake today?”: at 08:20 the response was count 0, stopReason noData and the warning The API returned no records for those parameters.
It is not an error: the USGS had no Chilean earthquakes for those filters that day.
The strongest earthquakes in Chile in the last year
With minMagnitude 5, orderBy magnitude and dates from 2025-11-24 to 2026-11-24, the top 10 were:
| Chile date and time | Magnitude | Depth | Place (USGS) |
|---|---|---|---|
| 25 May 2026, 17:52 | 6.9 | 109 km | 34 km ENE of Calama, Chile |
| 13 Mar 2026, 10:39 | 6.2 | 24 km | 71 km W of Vallenar, Chile |
| 12 Feb 2026, 10:34 | 6.1 | 46 km | 28 km SW of Ovalle, Chile |
| 31 May 2026, 17:34 | 6.0 | 25 km | 33 km NW of Valparaíso, Chile |
| 8 Feb 2026, 13:23 | 5.7 | 114 km | 79 km ENE of La Tirana, Chile |
| 11 Jun 2026, 08:22 | 5.5 | 9 km | 124 km NW of Vallenar, Chile |
| 9 May 2026, 22:34 | 5.5 | 35 km | 19 km ENE of Cañete, Chile |
| 13 Dec 2025, 09:18 | 5.4 | 90 km | 75 km W of Ollagüe, Chile |
| 15 Mar 2026, 05:28 | 5.3 | 10 km | Off the coast of Aisen, Chile |
| 20 Dec 2025, 17:30 | 5.3 | 151 km | 108 km SSE of Colchane, Chile |
The largest was the M6.9 on 25 May 2026, 17:52 (Chile time), 109 km deep near Calama, with a green PAGER alert and 85 reports from people who felt it.
Chile time and UTC
The USGS publishes times in UTC. The tool adds timeChile in the America/Santiago zone, which switches between summer and winter time:
- The latest earthquake:
timeUtc2026-11-22T21:47:32.112Z andtimeChile2026-11-22T18:47:32-03:00 (UTC−3, summer time). - The M6.9 near Calama:
timeUtc2026-05-25T21:52:20.140Z andtimeChile2026-05-25T17:52:20-04:00 (UTC−4, winter time).
Filter dates (fromDate, toDate) are also read in Chile time: an earthquake at 23:30 on 1 March in Chile falls on 2 March in UTC, and the tool counts it on 1 March. timeChile uses mainland Chile time, also for earthquakes near Easter Island, which has its own time zone.
Depth: shallow and deep earthquakes
Of the 37 magnitude 4+ earthquakes in the last month (2026-10-24 to 2026-11-24), 11 were 30 km deep or less ("maxDepthKm": 30) and 21 were deeper than 70 km, like those near Calama and Ollagüe, which are often over 100 km deep. At the same magnitude, a deep earthquake is usually felt less at the surface than a shallow one.
A depth of exactly 10 km (6 of those 37 earthquakes) is often a value fixed by the USGS when the depth could not be well determined, especially offshore. Treat it as approximate.
PAGER alert and tsunami flag
PAGER is the USGS estimate of impact on people and economic losses: green, yellow, orange or red. Many earthquakes have no alert (the field is absent). With "minAlertLevel": "yellow" over the last 10 years in Chile there were 7 earthquakes:
| Chile date and time | Magnitude | PAGER alert | Place (USGS) |
|---|---|---|---|
| 6 Jun 2025, 13:15 | 6.4 | yellow | 45 km SW of Diego de Almagro, Chile |
| 12 Nov 2022, 23:24 | 6.2 | yellow | Near the coast of Bio-Bio, Chile |
| 17 Jul 2020, 01:40 | 5.9 | yellow | 3 km SE of Iquique, Chile |
| 4 Nov 2019, 18:53 | 6.1 | yellow | 29 km SW of Illapel, Chile |
| 19 Jan 2019, 22:32 | 6.7 | orange | 10 km SSW of Coquimbo, Chile |
| 24 Apr 2017, 18:38 | 6.9 | yellow | 40 km W of Valparaíso, Chile |
| 25 Dec 2016, 11:22 | 7.6 | yellow | 41 km SW of Quellón, Chile |
Only one had an orange alert: the M6.7 near Coquimbo on 19 January 2019. Magnitude alone does not tell the impact: the M7.4 on 18 July 2024 near San Pedro de Atacama, 127 km deep, had a green alert.
tsunamiFlag is an informational USGS flag for large earthquakes at sea or near the coast; it is not a tsunami warning. With "tsunamiOnly": true there were 11 earthquakes in 10 years and none in the last year. In Chile, tsunami warnings are issued by SHOA and SENAPRED.
Areas: mainland Chile, islands or a radius
chile(default): mainland Chile and its coast. Drops events the USGS places in neighbouring countries (onlyChile).chile_islas: adds the ocean out to Easter Island and Juan Fernández. In the last month, at M4.5 or more, it returned 21 earthquakes versus 15: the 6 extra ones were on the West Chile Rise and southeast of Easter Island.radio: a circle of up to 2,000 km aroundlatitudeandlongitude(your city, plant or site), with the distance indistanceKm. In this mode events in neighbouring countries are kept unless you pass"onlyChile": true.
For earthquakes people reported feeling, use "feltOnly": true: there were 10 in the last month, and the one with the most reports was near Huara, with 21. There were none in the last week.
Errors and limits
Real errors (the response has isError and a clear message, in Spanish):
- Another date format:
"fromDate" debe ser AAAA-MM-DD (recibido: 24-11-2026).
- Radius without coordinates:
Con region "radio" debes indicar "latitude" y "longitude".
- More than 10 years:
El rango máximo es de 10 años por ejecución.
For long series, split into chunks of up to 10 years. Each call returns up to 500 earthquakes (maxItems, 20 by default); if stopReason is maxItems, narrow the dates or raise the minimum magnitude.
Earthquakes from your AI agent (MCP)
Add Better Llama's MCP server to your client (Claude, Cursor, VS Code or any other with remote MCP). One MCP brings get_chile_earthquakes and the rest of the catalog, with no sign-up during the beta.
{
"mcpServers": {
"better-llama": {
"url": "https://mcp.betterllama.com/mcp"
}
}
}claude mcp add --transport http better-llama https://mcp.betterllama.com/mcpSetup for Claude, Codex, Gemini CLI, Windsurf, VS Code and other clients: connect your agent.
Ready-to-run Python and Node.js examples, with config files for each client: examples repository on GitHub.
Then ask, for example: “What was the latest earthquake in Chile and what time was it in Chile?” or “Were there any magnitude 5+ earthquakes near Valparaíso this year?” The agent answers with USGS data and the source cited, instead of guessing.
Beta: free and with no sign-up while we test the service.
Pricing
Free during the beta, no sign-up, with a limit of 60 requests per minute per IP. USGS data is free. If paid plans come later, we will announce them first on betterllama.com.
Frequently asked questions
How do I get the latest earthquake in Chile by API?
Call get_chile_earthquakes with maxItems set to 1. It searches the last 7 days in mainland Chile and its coast, from magnitude 2.5, newest first. On 24 November 2026 at 08:20 it returned an M4.5 54 km north-northeast of Calama, on 22 November at 18:47 Chile time.
Is there an official Chile earthquake API?
Chile's Centro Sismológico Nacional (CSN) publishes official seismological information at sismologia.cl, but its data use page only allows academic and outreach use with attribution; any other use needs its written approval. The USGS offers a public API with its worldwide, public-domain catalog, which includes Chile's earthquakes; this tool uses that API.
Do I need an API key to query earthquakes?
No. The USGS API needs no key and Better Llama's tool is free during the beta, with no sign-up, over MCP or JSON-RPC, with a limit of 60 requests per minute per IP.
Why don't I see every tremor the CSN reports?
Because the tool uses the USGS catalog, which for Chile focuses on moderate earthquakes: for the week to 24 November 2026 it returned 9 earthquakes, all magnitude 4.0 or more. USGS magnitudes and locations can also differ from the CSN's, especially in the first minutes.
Are times in Chile time?
Yes. Each earthquake has timeUtc and timeChile, in the America/Santiago zone with its offset (UTC−3 in summer, UTC−4 in winter). The fromDate and toDate filters are read in Chile time.
How do I find earthquakes near my city?
Use region radio with latitude, longitude and radiusKm (up to 2,000 km). Each earthquake has distanceKm. For example, within 150 km of Santiago between 24 October and 24 November 2026 there were 3 earthquakes; the closest was 84.6 km away.
Can it be used as an earthquake or tsunami alert?
No. It is not an early warning or tsunami warning system. tsunamiFlag is an informational USGS flag and alertLevel is the PAGER impact estimate, not official alerts. In an emergency, follow SENAPRED and SHOA instructions.
Is Better Llama affiliated with the USGS, the CSN or SENAPRED?
No. Better Llama is an independent project, not affiliated with, sponsored by or endorsed by the USGS, the CSN, SENAPRED or SHOA. The data comes from the USGS, is public domain, and every earthquake includes an attribution field crediting the source.
Keep going
- Chile open data APIs: every official source available by API and MCP, with a real call per family.
- Chile electricity market API guide: generation and demand of the power system, useful to check operations after an earthquake.
- Chile Official Gazette API guide: decrees published every day, such as disaster zone declarations.
- Chile Earthquakes tool page: parameters, example and FAQ.
Other guides
- Chile open data APIs: official sources by API and MCP — map of the official Chilean sources available by API and MCP, how to find the tool with search_tools, one real call per family and an index of every guide.
- Chile public holidays API: 2026 holidays, business days and RUT — National, regional and local holidays with no key, curl and Python examples, and MCP usage.
- Chile business days API: deadlines and business-day counts — business-day deadlines from a notice date, Saturdays as business days, calendar days, business days per month, regional holidays and edge cases, with curl, Python and JavaScript, and MCP usage.
- Chile communes API: regions, provinces and CUT codes — all 346 communes with CUT codes, region filters, name search, curl, Python and JavaScript examples, and MCP usage.
- Chile RUT validation API: check digit as JSON — the modulo 11 algorithm, accepted formats, computing the check digit, batches and privacy, curl, Python and JavaScript examples, and MCP usage.
- Chile public procurement API: Mercado Público tenders and purchase orders — ChileCompra ticket, curl and Python examples, and MCP usage.
- Chile economic indicators API: UF, dollar, euro, CPI and TPM — One real call per indicator (UF, dollar, euro, UTM, CPI, TMC, TIP, TPM, Imacec, GDP, unemployment and real exchange rate), from the CMF or the Central Bank, with curl, Python, JavaScript and MCP.
- Chile UF API: the Unidad de Fomento value as JSON — today's UF, full month, next month's days already published, range or year, with CMF data and a Central Bank cross-check, curl, Python and JavaScript examples, and MCP usage.
- Chile USD/CLP exchange rate API: the observed dollar as JSON — today's rate, daily series by month, range or year and the warning for values published in advance, with CMF data, curl, Python and JavaScript examples, and MCP usage.
- Central Bank of Chile API: BDE series as JSON — dollar, UF, policy rate, CPI, Imacec, GDP, unemployment and any series by code, series search, curl, Python and JavaScript examples, and MCP usage.
- Chile CMF API: UF value, dollar, UTM and maximum conventional rate — the seven API CMF Bancos series with no API key to request, curl and Python examples, and MCP usage.
- Chile fuel prices API: gasoline 93, 95, 97, diesel and LPG from Bencina en Línea — CNE data with no sign-up, the cheapest by comuna or near a point, curl, Python and JavaScript examples, and MCP usage.
- Chilexpress API: coverage by comuna, shipping quotes and tracking — covered comunas and sectors with their code and no key, names that differ from the official ones, quotes and tracking with your free keys, and MCP usage.
- Chile Official Gazette API: laws, decrees and new companies — Laws, decrees, notices and company incorporations with CVE and official PDF, no key, curl and Python examples, and MCP usage.
- Chile electricity market API: marginal cost, generation and demand — Coordinador Eléctrico Nacional grid data with no user_key to request, curl and Python examples, and MCP usage.
- Colombia SECOP II API: public procurement contracts and processes — Open data from datos.gov.co with no key, curl and Python examples, and MCP usage.
- Colombia TRM API: today's TRM and the COP/USD rate — Superintendencia Financiera data via datos.gov.co with no key, curl and Python examples, and MCP usage.
- Peru BCRP API: exchange rate, inflation and rates — BCRPData series with no key, curl and Python examples, and MCP usage.
- Banxico API: Mexico's FIX exchange rate, UDIS and TIIE — Banco de México SIE indicators with no token to request, curl and Python examples, and MCP usage.
This guide is also available en español.