Back to ipdata.co in Google Sheets
SheetXAI logo
ipdata.co logo
ipdata.co · Google Sheets Guide

Map ASN Numbers to Routing Metadata in a Google Sheet Using ipdata.co

2026-05-14
5 min read

The Scenario

You are a network engineer. Your BGP monitoring tool has been collecting ASN numbers for six weeks, and the capacity planning review is next Friday. The output is sitting in an Excel sheet: 50 ASN numbers in column A, nothing else.

Your manager wants prefix counts, peer counts, and registry details — RIR, country, organization name — for each one. You could look them up in regional internet registries one by one. You could write a script that calls the ipdata.co advanced ASN endpoint for each row. Or you could spend the next three hours on something that actually requires your expertise.

The bad version:

  • Open RIPE NCC's web interface, search the first ASN, copy the prefix count, open the sheet, paste it, switch back, search the next.
  • The interface times out at ASN 12. Start over.
  • At ASN 25, realize you have been copying peer count into the prefix count column the entire time.

The capacity planning deck needs to be done before Friday's 2 PM review, not on Friday morning.

The Easy Way: One Prompt in SheetXAI

SheetXAI is an AI agent that lives inside your Google Sheet. It reads the ASN column, calls ipdata.co's advanced ASN lookup for each entry, and writes routing and registry metadata back into the columns you specify.

For each ASN in column A, call ipdata.co's advanced ASN lookup and write the organization name, country, RIR, prefix count, and peer count to columns B through F.

What You Get

  • Column B: organization name registered for the ASN (e.g., "AMAZON-02," "Deutsche Telekom AG")
  • Column C: country where the ASN is registered
  • Column D: RIR (e.g., "ARIN," "RIPE," "APNIC")
  • Column E: announced prefix count
  • Column F: peer count
  • ASNs that return no data noted in column B so nothing goes silently missing

What If the Data Is Not Quite Ready

The ASN column has mixed formats (AS12345 vs. plain 12345)

Normalize the ASN values in column A to plain integers (strip "AS" prefix if present), then call ipdata.co's advanced ASN lookup for each and write organization name, country, RIR, prefix count, and peer count to columns B through F.

You need the announced prefix list as well as the count

Look up all ASNs in column A using ipdata.co and write the announced prefixes as a comma-separated list to column B and the peer ASN list to column C. Write total prefix count to column D.

Some ASNs were collected from different monitoring tools and may be duplicates

Deduplicate column A by ASN number, keeping the first occurrence. Then look up each unique ASN using ipdata.co advanced lookup and write organization, country, RIR, prefix count, and peer count to columns B through F.

Kill-chain: normalize, deduplicate, enrich, and sort by prefix count for capacity review

Strip "AS" prefix from all values in column A and remove duplicates. Look up each unique ASN with ipdata.co advanced ASN endpoint and write organization name, country, RIR, prefix count, and peer count to columns B through F. Sort the result descending by prefix count so the largest networks appear at the top.

One prompt turns a raw ASN list into a capacity-planning-ready reference sorted by network size.

Try It

Get the 7-day free trial of SheetXAI and open your BGP monitoring sheet, then ask SheetXAI to enrich the ASN column with ipdata.co routing metadata. See also mapping IPs by continent and EU membership or the ipdata.co integration overview.

Stop memorizing formulas.
Tell your spreadsheet what to do.

Join 4,000+ professionals saving hours every week with SheetXAI.

Learn more