Bulk IP Checker


Updates to our Bulk IP address lookup tool. 

The bulk IP checker now supports both a web interface & an API for querying a batch of IP addresses to get location information.

The web interface lets you enter IP addresses along with your access credentials (see form below) and returns a JSON (or CSV / XML / YAML) file with geolocation data.


Web Interface for bulk IP lookup




Sample JSON Response


The API makes it convenient to get the location for a batch of IP addresses from your tool / program. Usage of the API is similar i.e. send a POST request with multiple IP addresses and get appropriate  response. 

Supported formats are JSON, CSV, XML, YAML

Visit ipapi.co to contact us with your requirements. 

Weather forecast from IP address

Recipe to get weather forecast from an IP address

Ingredients

  • IP address to location API : ipapi.co (free, no key required)
  • Weather API : openweathermap.org (free but requires key, signup to get one)

Ruby

require 'net/http'
require 'json'

$ip = '208.67.222.222'

$latlong = Net::HTTP.get(URI('https://ipapi.co/' + $ip + '/latlong/')).split(",")

$weather = JSON.parse(Net::HTTP.get(URI('http://api.openweathermap.org/data/2.5/weather?lat='+$latlong[0]+'&lon='+$latlong[1]+'&appid='+$API_KEY)))

Python

from requests import get

ip = '208.67.222.222'

latlong = get('https://ipapi.co/{}/latlong/'.format(ip)).text.split(',')

weather = get('http://api.openweathermap.org/data/2.5/weather?lat={}&lon={}&appid=API_KEY'.format(latlong[0], latlong[1])).json()

PHP

$ip = '208.67.222.222';

$latlong = explode(",", file_get_contents('https://ipapi.co/' . $ip . '/latlong/'));

$weather = file_get_contents('http://api.openweathermap.org/data/2.5/weather?lat=' . $latlong[0] . '&lon=' . $latlong[1] . '&appid=API_KEY');

echo $weather;

$json = json_decode($weather);

What is my IP

Find your public (external) IP address in your favorite language with a secure API 

Shell

curl 'https://ipapi.co/ip/'

Ruby

require 'net/http'
puts Net::HTTP.get(URI('https://ipapi.co/ip/'))

Python

from requests import get   
print get('https://ipapi.co/ip/').text

PHP

echo file_get_contents('https://ipapi.co/ip/')

Node.js

var https = require('https');

https.get('https://ipapi.co/ip/', function(resp){
    var body = ''
    resp.on('data', function(data){
        body += data;
    });

    resp.on('end', function(){
        console.log(body);
    });
});

jQuery

$.get('https://ipapi.co/ip/', function(data){
  console.log(data)
})