Rankings
GET
/v1/rankEvery reporting country ranked on one measure for one period.
Developer plan and upKey requiredJSON or CSVCached until the next release
Parameters
| Name | Type | Description |
|---|---|---|
| measurerequired | string query | arrivals, nights, spend, departures, occupancy or capacity e.g. arrivals |
| periodoptional | period query | One period; defaults to the latest finished one e.g. 2026-08 |
| limitoptional | integer query | Rows per page, 1 to 1000 e.g. 100 |
Request
# Countries ranked on any measure and period
curl "https://api.tourismapi.com/v1/rank?measure=arrivals&period=2026-08" \
-H "X-API-Key: $TOURISM_API_KEY"const res = await fetch("https://api.tourismapi.com/v1/rank?measure=arrivals&period=2026-08", {
headers: { "X-API-Key": process.env.TOURISM_API_KEY }
});
if (!res.ok) throw new Error(`Tourism API ${res.status}`);
const { meta, data } = await res.json();
console.log(meta.data_as_of, data);import os, requests
r = requests.get(
"https://api.tourismapi.com/v1/rank?measure=arrivals&period=2026-08",
headers={"X-API-Key": os.environ["TOURISM_API_KEY"]},
timeout=10,
)
r.raise_for_status()
body = r.json()
print(body["meta"]["data_as_of"], body["data"])$ch = curl_init("https://api.tourismapi.com/v1/rank?measure=arrivals&period=2026-08");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["X-API-Key: " . getenv("TOURISM_API_KEY")],
]);
$body = json_decode(curl_exec($ch), true);
print_r($body["data"]);
Example response
{
"meta": {
"request_id": "req_9c3babe112",
"data_as_of": "2026-10-20T04:48:17Z",
"count": 40,
"measure": "arrivals",
"period": "2026-08",
"note": "Each country's own headline series; units can differ (arrivals at hotels, at the border, or visitors)."
},
"data": [
{
"rank": 1,
"country": "HU",
"name": "Hungary",
"series": "sr_8dhrzswd",
"unit": "",
"period": "2026-08",
"value": 6916472,
"year_before": 7340976,
"yoy_pct": -5.8
},
{
"rank": 2,
"country": "HK",
"name": "Hong Kong",
"series": "sr_3e3rjawd",
"unit": "persons",
"period": "2026-08",
"value": 5456645,
"year_before": 5153244,
"yoy_pct": 5.9
},
{
"rank": 3,
"country": "MX",
"name": "Mexico",
"series": "sr_dr2x8n1d",
"unit": "visitors",
"period": "2026-08",
"value": 4216916,
"year_before": 4094085,
"yoy_pct": 3
}
]
}Response fields
| Field | Type | Example |
|---|---|---|
| rank | number | 1 |
| country | string | HU |
| name | string | Hungary |
| series | string | sr_8dhrzswd |
| unit | string | |
| period | string | 2026-08 |
| value | number | 6916472 |
| year_before | number | 7340976 |
| yoy_pct | number | -5.8 |