Full geolocation and network lookup for an IPv4 address, IPv6 address, or resolvable hostname. Returns country, continent, ASN, organisation name, and — as of v0.1 — the most-specific announced BGP prefix covering the IP. Cached for 7 days.
| Field | Type | Description |
|---|---|---|
| ip | string | Resolved IP address. May differ from input when a hostname is provided. |
| country_code | string | ISO 3166-1 alpha-2 code, e.g. "AU". |
| country | string | Full country name, e.g. "Australia". |
| country_flag | string | Unicode flag emoji, e.g. "🇦🇺". |
| continent | string | Full continent name, e.g. "Oceania". |
| as_number | number | ASN as an integer, e.g. 13335. |
| as_description | string | Organisation name from the routing registry, e.g. "CLOUDFLARENET". |
| cidrnew | string|null | Most-specific announced BGP prefix containing this IP, e.g. "1.1.1.0/24". null when the ASN has no prefix entries in the database. |
| error | null|string | Null on success. Error message on failure. |
Returns all CIDR prefixes announced by an ASN, annotated with country and continent data.
Now also includes pre-computed announcement size stats so consumers don't need
to iterate the full prefix list. :as_number accepts a bare integer or an
AS-prefixed string (e.g. 13335 or AS13335).
Cached for 24 hours.
| Field | Type | Description |
|---|---|---|
| as_number | number | The ASN as an integer. |
| as_description | string | Organisation name from the registry. |
| ipv4_countnew | number | Total IPv4 host addresses across all announced prefixes (sum of 2^(32−prefixLen)). |
| ipv6_prefix_countnew | number | Number of IPv6 prefix entries. IPv6 address space is too large to represent as a single sum. |
| cidrs | object[] | Array of prefix objects. |
| cidrs[].cidr | string | CIDR notation, e.g. "1.1.1.0/24". |
| cidrs[].country_code | string | ISO 3166-1 alpha-2 code for this prefix's allocation. |
| cidrs[].country | string | Full country name for this prefix. |
| cidrs[].continent | string | Full continent name for this prefix. |
| error | null|string | Null on success. |
Search ASNs by multiple input types — automatically detected from the query string.
Returns up to 25 matching { as_number, as_description } results.
| Input | Strategy |
|---|---|
| CIDR prefixnew | e.g. 1.1.1.0/24 — exact match against the prefix table. Returns the owning ASN. |
| IP address | e.g. 1.1.1.1 — resolves to the owning ASN via the IP range table. |
| AS number / "AS1234" | e.g. 13335 or AS13335 — direct lookup by number, single result. |
| Org name | e.g. cloudflare — case-insensitive partial match against organisation names, up to 25 results. |
Returns the full country name as a plain text string. Ideal for shell pipelines. Accepts IPv4, IPv6, or any resolvable hostname. Cached for 7 days.
Returns the bare ASN number as plain text — no "AS" prefix.
Returns the full continent name as plain text.
Atlas is free and unmetered. If you're using it in something cool, consider supporting continued development.
♥ Donate