esc
Networking IP & Network

What Is an ASN? Autonomous System Numbers Explained

By helpers.work Updated 9 min read
IP address 8.8.8.8 mapped to prefix 8.8.8.0/24 and autonomous system AS15169 Google LLC, with a BGP path through other autonomous systems

An ASN (Autonomous System Number) is a unique number that identifies a network on the internet, such as an ISP, a cloud provider, a university or a large company. Each of these networks is an autonomous system: a group of IP address ranges run by one operator under one routing policy. Networks use their ASN in BGP to tell each other which IP ranges they can deliver traffic to.

That makes the ASN the missing link between an IP address and the organization behind it. For example, 8.8.8.8 is in the prefix 8.8.8.0/24, which is announced by AS15169, Google.

ASN at a glance

IP address:  8.8.8.8
Prefix:      8.8.8.0/24
ASN:         AS15169
Organization: Google LLC
Registry:    ARIN
Term What it identifies Example
IP address One network interface 8.8.8.8
Prefix A block of IP addresses routed together (CIDR) 8.8.8.0/24
Autonomous system A network run by one operator with one routing policy Google's network
ASN The number that identifies that autonomous system AS15169

You can look up any IP with the IP Lookup, or any AS number with the ASN Lookup.

How autonomous systems and BGP work

The internet is not one network. It is tens of thousands of independent networks that agree to exchange traffic. More than 75,000 autonomous systems are visible in the global routing table, and many more numbers have been assigned.

Each network uses BGP (Border Gateway Protocol) to announce the prefixes it originates to its neighbors. The neighbors pass those announcements on, adding their own ASN to the AS path. Every router on the internet ends up with a table of prefixes and the chain of networks that leads to each one.

Prefix:   8.8.8.0/24
AS path:  AS3356 AS15169
          ^^^^^^ ^^^^^^^
          transit origin (the network that owns the route)

The last ASN in the path is the origin AS, the network that announced the prefix. When you look up the ASN of an IP address, you are finding the origin AS of the most specific prefix that contains it.

Networks connect to each other in two main ways:

  • Transit (upstream): a provider carries your traffic to the rest of the internet, usually for a fee. Lumen (AS3356), Arelion (AS1299) and Cogent (AS174) are large transit networks.
  • Peering: two networks exchange traffic between their own customers directly, often at an internet exchange point (IXP), usually without payment.

ASN numbers, ranges and formats

ASNs were originally 16-bit numbers, from 1 to 65535. When those started running out, 32-bit ASNs were introduced (RFC 6793), which allow values up to 4294967295. Today, most newly assigned ASNs are 32-bit.

Range Purpose
0 Reserved, never used in routing
1 – 64495 Public 16-bit ASNs
23456 AS_TRANS, a placeholder used by older routers for 32-bit ASNs
64496 – 64511 Documentation and examples
64512 – 65534 Private use (16-bit)
65535 Reserved
65536 – 65551 Documentation and examples (32-bit)
65552 – 4199999999 Public 32-bit ASNs
4200000000 – 4294967294 Private use (32-bit)
4294967295 Reserved

Private ASNs work like private IP ranges such as 10.0.0.0/8. Organizations use them inside their own networks or between a customer and its provider, and providers remove them before announcing routes to the rest of the internet.

32-bit ASNs are normally written as a plain number (asplain), such as AS4200000000. Some older tools use the asdot format, which splits the number into two 16-bit halves: AS65536 becomes AS1.0.

Who assigns ASNs

IANA gives blocks of ASNs to the five regional internet registries (RIRs), which assign them to organizations in their region:

RIR Region
AFRINIC Africa
APNIC Asia-Pacific
ARIN Canada, the United States and parts of the Caribbean
LACNIC Latin America and parts of the Caribbean
RIPE NCC Europe, the Middle East and Central Asia

An organization usually needs its own ASN when it connects to two or more providers (multihoming) or wants to control its own routing policy. A small business with a single ISP normally uses the ISP's ASN.

What an ASN reveals about an IP address

  • Who operates the network. The organization behind the ASN, such as AS13335 for Cloudflare or AS16509 for Amazon.
  • The type of network. Whether the IP belongs to a residential ISP, a mobile carrier, a hosting or cloud provider, a CDN, a university or a corporate network.
  • The size of the network. How many IPv4 and IPv6 prefixes the AS announces and how many addresses they cover.
  • How it connects. Its upstream providers and peers, which explain how traffic reaches it.
  • The registry and country where the ASN is registered, and an abuse contact for reporting problems.

Some well-known examples:

ASN Organization Type
AS15169 Google Cloud and content
AS13335 Cloudflare CDN and DNS
AS16509 Amazon (AWS) Cloud hosting
AS8075 Microsoft Cloud and content
AS3356 Lumen (formerly Level 3) Transit
AS174 Cogent Transit

What an ASN does not tell you

  • The exact owner of a single IP. The AS that routes an address is not always the organization that holds it. A provider can announce space for its customers, and leased or recently transferred ranges may still show the previous network. Check WHOIS or RDAP data when ownership matters.
  • The physical location. An ASN is registered in one country but can announce prefixes used worldwide. Anycast networks, such as Cloudflare's 1.1.1.1, announce the same prefix from hundreds of locations.
  • The person behind the traffic. An ASN identifies a network, not a user, and a VPN or proxy hides the user's own network.

Where ASN data is useful

Abuse and fraud analysis

Attackers rotate through many IP addresses, but those addresses often belong to one hosting ASN. Grouping suspicious sign-ups or login attempts by ASN reveals patterns that per-IP analysis misses. A burst of traffic from data center ASNs on a consumer-facing sign-up form is a strong sign of automation, while the same traffic from residential ISPs is usually ordinary users. Treat it as a signal, not proof: VPN users and corporate networks also appear on data center ASNs.

Debugging routing problems

When a service is slow or unreachable from one region only, the AS path shows which networks sit between you and the destination. A traceroute combined with ASN lookups for each hop often points to one transit network in the middle, not a fault at either end.

Security and route hijacks

Because BGP trusts announcements by default, a network can announce a prefix it does not own, by mistake or on purpose. In 2008, Pakistan Telecom (AS17557) announced part of YouTube's address space and took YouTube offline in much of the world. RPKI (Resource Public Key Infrastructure) reduces this risk: the address holder publishes a signed ROA (Route Origin Authorization) that says which ASN may originate its prefixes, and networks that validate RPKI drop announcements marked invalid.

Research and due diligence

Listing every prefix an organization's ASN announces shows the real size of its internet presence, often much larger than a single domain suggests. It is also useful for allowlists, firewall rules and geolocation checks.

How to find the ASN of an IP address

With a web tool: paste the IP into the IP Lookup. It shows the ASN, organization and prefix, and links to the ASN page. Given an AS number instead, the ASN Lookup lists the organization, registry, prefixes and peers. To check your own connection, use What Is My IP.

On the command line: Team Cymru runs a public IP-to-ASN whois service:

whois -h whois.cymru.com " 8.8.8.8"
AS      | IP               | AS Name
15169   | 8.8.8.8          | GOOGLE, US

Add -v inside the quotes (" -v 8.8.8.8") to also get the BGP prefix, country, registry and allocation date.

To list the routes an ASN has registered in routing registries (IRR), query RADb:

whois -h whois.radb.net -- '-i origin AS15169'

Registry data in IRRs is published by the networks themselves and is not always up to date. For the most accurate picture, compare it with what is actually announced in BGP.

Summary

An ASN identifies an autonomous system: one network, run by one operator, that announces IP prefixes to the rest of the internet using BGP. Looking up the ASN of an IP address tells you which network routes it, what kind of network it is and how large it is. That is useful for abuse analysis, routing problems and research, as long as you remember that routing data is not the same as legal ownership.

Look up any address with the IP Lookup, explore networks such as AS15169 with the ASN Lookup, and confirm registration details with the WHOIS Lookup.

FAQ

Frequently asked questions

What is an ASN in simple terms?

An autonomous system number is a unique ID for a network on the internet, such as an ISP, a cloud provider or a large company. Networks use it in BGP to announce which IP address ranges they route, so an ASN links an IP address to the network that operates it.

How do I find the ASN of an IP address?

Use an IP lookup tool that includes routing data. It finds the prefix that contains the IP and the ASN that announces it. On the command line, the Team Cymru whois service returns the same information.

What is the difference between an ASN and an IP address?

An IP address identifies a single interface. An ASN identifies a whole network that may announce thousands or millions of IP addresses in many prefixes. One ASN usually covers many IP addresses.

Who assigns ASNs?

IANA gives blocks of ASNs to the five regional internet registries: AFRINIC, APNIC, ARIN, LACNIC and RIPE NCC. They assign individual ASNs to organizations in their region that need to run their own routing policy.

What is a private ASN?

Private ASNs, 64512 to 65534 and 4200000000 to 4294967294, are reserved for internal use, much like private IP ranges. They are used inside organizations and between a customer and its provider, and should never appear in the public routing table.

Does an ASN show the exact owner of an IP address?

It shows the network that routes the address, which is usually but not always the organization that holds it. Customers, leased ranges and recent transfers can differ, so check WHOIS or RDAP registration data when it matters.

Try it yourself

Related tools

All tools

More guides in the helpers.work blog

Practical, no-nonsense guides on DNS, email, networking and security — plus 68 free tools to go with them.

Read the blog Browse all tools