How to Get an IPinfo API Token?

If you are building location-aware features, personalized websites, geo-targeted content, cybersecurity tools, or analytics dashboards, you have probably come across IPinfo, one of the most reliable and developer-friendly IP geolocation services on the internet.

Whether you need something simple like country detection or you want complex datasets such as ASN information, VPN detection, company details, privacy flags, and city level data, IPinfo gives you everything through their powerful API.

In this detailed guide, you will learn:

  • What IPinfo is and what it can do
  • Differences between Lite Token and Full API Token
  • How to sign up for IPinfo and get your token
  • How to locate your API token inside the dashboard
  • How to test the API token with real examples
  • How to secure your API token
  • How to upgrade to paid plans
  • How to use the token with WordPress or custom applications

This is the most complete guide you will find online. Let us begin.

What Is IPinfo and Why Do You Need an API Token

IPinfo is a leading IP intelligence platform trusted by developers, businesses, cybersecurity experts, and large organizations worldwide. It provides accurate and constantly updated information about any IP address. This includes:

  • Country
  • Region
  • City
  • Latitude and longitude
  • Postal code
  • Continent
  • ASN and ISP information
  • Privacy insights
  • VPN, hosting, and proxy detection
  • Company information
  • Domains connected to IPs

To access this data programmatically, IPinfo provides a REST API. Every request requires an API Token, which identifies you and applies usage limits.

There are two types of tokens:

1. IPinfo Lite API Token

  • Totally free
  • Unlimited in most cases
  • Returns only basic country data
  • No city, region, ASN, ISP, or privacy data
  • Used for plugins like geo-targeting, basic personalization, or location based content

2. IPinfo Full API Token

  • Free tier available
  • Paid plans for higher limits or advanced datasets
  • Returns detailed geolocation data
  • Includes ASN, carrier, privacy, hosted details, company information, and more

Both tokens are created in the same dashboard, but their usage depends on the API endpoint you call.

Lite Token vs Full API Token: Which One Should You Choose

Before creating an account, it helps to understand the difference between IPinfo Lite and the Full API.

Lite Token

  • Perfect for websites that only need the country
  • Useful for WordPress plugins like Geo Targeting for Bricks Builder
  • API endpoint: https://ipinfo.io/lite
  • Response example: { "ip": "8.8.8.8", "hostname": "dns.google", "country": "US" }

Full Token

  • Required if you need city, region, ISP, ASN, or privacy data
  • Ideal for SaaS apps, dashboards, cybersecurity, analytics
  • API endpoint: https://ipinfo.io/8.8.8.8?token=YOUR_TOKEN
  • Response example: { "ip": "8.8.8.8", "hostname": "dns.google", "city": "Mountain View", "region": "California", "country": "US", "loc": "37.4056, -122.0775", "org": "AS15169 Google LLC", "postal": "94043", "timezone": "America/Los_Angeles" }

If your project only needs the country, Lite is ideal.
If you need more detailed data, the full API token is required.

Let us now create both.

Step-by-Step Guide: How to Create an IPinfo Account

Follow these steps to create your account on IPinfo.

Step 1. Visit the IPinfo Dashboard

Go to: https://ipinfo.io/dashboard

This page will show the login or signup options.

Step 2. Choose Sign Up

You can sign up using:

  • Email
  • GitHub
  • Google

All three options lead to the same dashboard.

Step 3. Verify Your Account

If you sign up using email, IPinfo will send a verification link. You must verify before the token becomes active.

After completing this step, you will land on the main dashboard.

How to Get the IPinfo Lite API Token

The Lite token is the simplest because it does not require creating a full API key. It works instantly.

Step 1. Open the Lite API page

Visit this URL directly: https://ipinfo.io/developers/lite

Scroll down and you will see: Your Lite Token: XXXXXXXXXXXXX

Step 2. Copy the Lite Token

It will look something like: 1234567890abcdef1234567890abcdef

This token is all you need to use the Lite endpoint.

Step 3. Use the Lite API endpoint

To detect your own IP: https://ipinfo.io/lite?token=YOUR_TOKEN

To detect a specific IP: https://ipinfo.io/lite/8.8.8.8?token=YOUR_TOKEN

This is the token used by most WordPress plugins that only need the country.

How to Get the Full API Token for Detailed IP Data

If you need more than just the country, follow these steps to get your full API token.

Step 1. Login to the Dashboard

Visit: https://ipinfo.io/dashboard

Step 2. Go to the Token Section

You will see a panel labeled:

Your API Token

Example: 12345a6789b12cde345fa67890b12345

This is your full API key.

Step 3. Copy the Token

Click the copy button next to it.

Step 4. Test the Token

Try a test API call in your browser:

https://ipinfo.io/8.8.8.8?token=YOUR_TOKEN

You will get the full JSON response with:

  • City
  • Region
  • Country
  • Location
  • Latitude and longitude
  • Postal code
  • ASN
  • ISP
  • Timezone
  • Privacy details if enabled

Now you have the full token ready for integration.

How to Test IPinfo API Using Command Line or Tools

Test using curl

curl https://ipinfo.io?token=YOUR_TOKEN

Test using Postman

  1. Create a GET request
  2. URL: https://ipinfo.io/json?token=YOUR_TOKEN
  3. Click Send
  4. View the JSON response

Test Lite API

curl https://ipinfo.io/lite?token=YOUR_TOKEN

How to Use the Token in WordPress and Plugins

Many plugins require an IPinfo token. Geo Targeting for Bricks Builder, uses the Lite token.

Using the Lite Token in WordPress

Paste the token inside: Bricks > Geo Rules > IPinfo Lite Token

That is it. The plugin will automatically use the API for country detection.

Rate Limits and Pricing Explained

Lite API

  • Completely free
  • Unlimited in most real world scenarios
  • Only country level information

Full API

Free tier includes:

  • 50 thousand requests per month
  • Basic datasets

Paid plans unlock:

  • Higher request limits
  • Privacy detection
  • Hosting detection
  • Company and ASN data
  • VPN and proxy detection

Pricing starts at affordable levels, depends on your usage and dataset type.

How to Secure Your IPinfo API Token

Your API token should not be exposed in public code repositories.

Here are best practices:

  1. Store tokens in environment variables
  2. Do not commit tokens to GitHub
  3. Use server side API calls whenever possible
  4. If using client side calls, restrict usage by domains in the dashboard
  5. Rotate your token periodically
  6. Regenerate token if accidentally exposed

Regenerating a Token

In the dashboard, click Regenerate Token.
Your old token will stop working instantly.

IPinfo API Endpoints You Should Know

Here are the most common endpoints.

Detect your own IP

https://ipinfo.io/json?token=YOUR_TOKEN

Get info for any IP

https://ipinfo.io/8.8.8.8?token=YOUR_TOKEN

Lite endpoint

https://ipinfo.io/lite?token=YOUR_TOKEN

ASN information

https://ipinfo.io/AS15169?token=YOUR_TOKEN

Privacy details (VPN, TOR, Proxy)

https://ipinfo.io/8.8.8.8/privacy?token=YOUR_TOKEN

How to Use IPinfo API in PHP

Here is a simple PHP example:

$token = "YOUR_TOKEN";
$ip = $_SERVER["REMOTE_ADDR"];
$url = "https://ipinfo.io/{$ip}?token={$token}";
$response = wp_remote_get($url);
$data = json_decode(wp_remote_retrieve_body($response), true);
echo "Country: " . $data["country"];

Lite token example in PHP

$token = "YOUR_LITE_TOKEN";
$url = "https://ipinfo.io/lite?token={$token}";
$response = wp_remote_get($url);
$data = json_decode(wp_remote_retrieve_body($response), true);

How to Use IPinfo API in JavaScript

fetch("https://ipinfo.io?token=YOUR_TOKEN")
  .then(res => res.json())
  .then(data => {
    console.log(data.country);
  });

Troubleshooting Common Issues

1. Token not working

Make sure you copied the token correctly.

2. API returns error 429

Too many requests. Slow down or upgrade the plan.

3. Wrong location

Reasons can be:

  • VPN
  • Proxy
  • ISP routing
  • Mobile networks

IPinfo has a high accuracy rate but not perfect in all countries.

4. Country detected as blank

If using Lite API, fallback to default country in your app.

Final Thoughts

IPinfo is one of the easiest and most powerful IP intelligence services available for developers. Whether you are using the Lite token for country level detection or the Full API token for advanced datasets, IPinfo provides fast, reliable, and accurate results.

Leave a Reply

Your email address will not be published. Required fields are marked *

Interested in working with us? We'd love to hear more.

Tell us about your project, and we’ll send you detailed pricing and timeline information within 24 hours.

Interested in working with us? We'd love to hear more.

Tell us about your project, and we’ll send you detailed pricing and timeline information within 24 hours.