IPinfo on Google Cloud Platform

This document explores how to use our IP database within the Google Cloud Platform (GCP)'s data warehouse platform, BigQuery, delivered through Google Marketplace.

GCP Analytics Hub to BQ

IPinfo Datasets available on Google Cloud Platform

The GCP integration allows our users to access the following features:

  • Automatic loading into BigQuery: No need for custom scripts; data is automatically loaded into BigQuery.
  • Built-in metadata: Tracks updates and ensures data freshness.
  • Efficient query functions: Ready-to-use, highly optimized query functions with clear documentation.
  • Centralized data: Simplifies IP data enrichment across other datasets and logs in BigQuery.

Just like our Cloud Data Push and Snowflake datasets, we keep your GCP IP datasets in your BigQuery environment up to date with regular updates — you don’t need to do anything after the initial subscription. The data you query on your BQ environment is the latest data we have!

Available Datasets

We offer our IPinfo Lite database through the Google Cloud Analytics Hub platform, but for our premium databases like IPinto Core, IPinfo Plus, and any custom IP databases, we offer them through the Google Cloud Marketplace. Getting started only takes a click of a button.

IP DatabaseRegionAccessFeatures
IPinfo LiteUS / DefaultSelf Serve – FreeAccurate country and ASN info for free—no fees, no credit card, and unlimited usage.
EU
IPinfo CoreUS / DefaultSelf Serve - PremiumProvides city-level accuracy along with key IP privacy details, such as VPN, hosting, satellite, and carrier detection.
EU
IPinfo PlusUS / DefaultComprehensive IP data with detailed context, including service classifications, confidence scores, and stability metrics.
EU
Any IP databaseAny Region / Any DataOn RequestAny and all IP data available to be offered by IPinfo.

Features

IPinfo BigQuery Datasets

Customers can access IPinfo IP data in BigQuery in the following ways:

Database TypeSourceAccess
IPinfo Lite (Free)Available on GCP Analytics HubSelf-serve
IPinfo Core and PlusAvailable on Google Cloud MarketplaceSelf-serve
Custom IP DatasetsContact sales team via listing formContact to purchase

IP Lookup Mechanism

IP datasets require specialized solutions to look up IP addresses. We recommend using our lookup method instead of building your own, as it’s optimized for the best performance. Our query functions support both IPv4 and IPv6 and offer an extremely efficient and easy-to-use solution.

DatabaseDataset NameTableQuery Function
IPinfo Litelitelitelite
IPinfo Lite – EUlite_eu
IPinfo Corecorecorecore
IPinfo Core – EUcore_eu
IPinfo Plusplusplusplus
IPinfo Plus – EUplus_eu

GCP Project Regions

When integrating IPinfo's datasets into Google Cloud Platform (GCP) via BigQuery, understanding the implications of region selection is crucial.

As a standard offering, IPinfo generally offers datasets in multiple regions:

  • US (Multi-region)
  • EU (Multi-region)

We can offer custom data sharing options that include data shares to specific regions.

If you have project region restrictions in place, meaning that you cannot access GCP resources located in other regions, you should opt for a custom data share agreement.

For example, imagine all your organizational GCP resources are in a single region of europe-west3 and you do not allow access to GCP resources in other regions. In this case, accessing our dataset could be difficult, even with the EU multi-region dataset. To evaluate our data, we recommend creating either a US or EU region BigQuery dataset, where you can import your log/test data for testing. Once the evaluation is complete, we can deliver the data to any specific region you prefer under a custom data share agreement. No BigQuery replication is required on the client side to access those datasets.

In general, you can access data resources in another region from your current infrastructure region, unless access control restrictions are in place. Please note that "regions” here refers to GCP infrastructure regions, not the physical location of the user or the company.

If you do not have a dataset in the US/EU (Multi-region) and cannot perform IPinfo BQ data evaluation, you can create a test dataset in those regions and bring our data there.

  1. Go to the BigQuery Console.
  2. Click your project name in the Explorer panel.
  3. Click Create Dataset.
  4. In the Dataset ID field, enter a name.
  5. Under Data location, select either:US (multi-region) or EU (multi-region)
  6. Click Create Dataset.

For more details on supported regions and best practices, refer to Google’s BigQuery location documentation. After the evaluation, the team will discuss custom data delivery to specific region options for you.

Bringing log data from Cloud Logging

BQ Log Analysis

As the IPinfo data resides in BigQuery, you can bring in log data from GCP Cloud Logging and perform IP metadata enrichment (geolocation, privacy, ASN, etc.) inside BigQuery. We recommend checking the documentation provided by Google. Visit View logs routed to BigQuery.

We recommend ensuring that only distinct IP addresses are enriched instead of all the IP addresses in a log.

SELECT ip, ipinfo_lite.lite(ip)
FROM (SELECT DISTINCT ip FROM my_ips)

As Cloud Logging supports many different sources, IPinfo's data inside BigQuery acts as a powerful data enrichment and analytics platform.

IPinfo Lite database on GCP BigQuery

IPinfo Lite on Analytics Hub

IPinfo's Lite data is available on Google Cloud Analytics Hub:

Resources included

The IPinfo Lite BigQuery Dataset contains the following resources:

ResourcesTypeDescription
liteTABLEThe main IPinfo Lite Dataset. Full accuracy and daily updated (from our end).
ip_sampleTABLESample of IP addresses to test out queries and learn.
lite (available in routines)FUNCTIONQuery function, lookup IP address against the IP table
gen_ranges (available in routines)FUNCTIONHelper function used to support the Query function

Using the lite query function

Lite UDF Query demo

We include a IP lookup function with our BigQuery datasets. It’s located in the dataset’s routine directory and shares the same name as the IP data table. No custom code is needed to start using it.

Example:

SELECT
	ip,
	ipinfo_lite.lite(ip) as lite
FROM
	ipinfo_lite.ip_sample;

Code notes:

  • ip_sample holds some random IP addresses.
  • lite() is the UDF packaged with the dataset. The UDF name matches the dataset name, with () indicating it's a function.

Besides getting all the data at once, you can also specify individual columns of data that you need.

SELECT
	ip,
	ipinfo_lite.lite(ip).country as lite
FROM
	ipinfo_lite.ip_sample;

You can also look up single IP addresses as well

SELECT ipinfo_lite.lite('8.8.8.8')as lite

IPinfo Core, IPinfo Plus, and other data on GCP Analytics Hub

Other than our IPinfo Lite database, we also have our data in Google Cloud Marketplace. The databases themselves come with our query UDF, and there is no friction to get started today.

Google Marketplace


We welcome your feedback and if you have any feature requests or need support using the BQ IPinfo dataset, please create a post in our IPinfo Community.