IP-API.io
Free IP address lookup location database, IP geolocation API, and email validation service. Trusted by thousands of businesses.
Country
Germany
Country Code
DE
City
Berlin
ZIP / Postcode
13409
Timezone
Europe/Berlin
Local Time
2024-05-20T22:16:52+02:00
Latitude
52.5694
Longitude
13.3753
All IP location and email data in one API
Explore a comprehensive suite of Geo IP location features for effective regional analysis and security management.
Accurate Geolocation
Locate customers globally without their consent using precise IP-based geolocation data.
Simple Integration
Integrate our straightforward JSON API quickly and start retrieving IP location data in minutes.
Enhanced Security
Secure every request with HTTPS/SSL encryption to ensure data integrity and confidentiality.
Comprehensive Network Data
Access detailed ISP and ASN information from any IP address.
Effective Geotargeting
Utilize IP geolocation for refined ad targeting, DRM, content personalization, and geofencing.
Expand Global Reach
Extend your market presence worldwide effortlessly with our Geo IP data.
Boost Conversions
Enhance conversion rates up to 75% with localized content and dynamic pricing strategies.
Automated User Experience
Improve user experience by automating form completions with accurate geolocation data.
Advanced Security Insights
Identify potential security threats such as VPNs, proxies, and bots with our comprehensive threat analysis tools.
Email Validation Endpoint
Verify the validity of email addresses with our new email validation endpoint, ensuring accurate and reliable user data.
Disposable Email Detection
Detect and filter out disposable email addresses to maintain the quality of your user database.
Email Syntax Verification
Ensure email addresses are correctly formatted and identify common errors, enhancing data integrity.
Detailed Email Address Error Reporting
Receive comprehensive error reports for invalid email addresses, including specific reasons for validation failures.
Email Username Extraction
Extract the username component from email addresses to facilitate personalized user interactions.
API Documentation
IP Geolocation API Endpoints
Get Client's IP Information
Get Specific IP Information
API Response Format
Geolocation API returns a JSON object with the following structure:
{
"ip": "78.55.53.58",
"suspicious_factors": {
"is_proxy": false,
"is_tor_node": false,
"is_spam": false,
"is_crawler": false,
"is_datacenter": false,
"is_vpn": false,
"is_threat": false
},
"location": {
"country": "Germany",
"country_code": "DE",
"city": "Berlin",
"latitude": 52.5694,
"longitude": 13.3753,
"zip": "13409",
"timezone": "Europe/Berlin",
"local_time": "2024-05-20T22:16:52+02:00",
"local_time_unix": 1716236212,
"is_daylight_savings": true
}
}
Geo Location by IP: Code Examples
This method is ideal for front-end implementations, making API calls from the browser to retrieve the client's IP information.
const request = require('request-promise');
request('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY')
.then(response => console.log(JSON.parse(response)))
.catch(err => console.log(err));
$.getJSON('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY', data => console.log(data));
import axios from 'axios';
axios.get('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY')
.then(response => console.log(response.data));
fetch('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY')
.then(response => response.json())
.then(data => console.log(data))
.catch(err => console.error(err));
import { useQuery } from 'react-query';
import axios from 'axios';
const fetchIPData = async () => {
const { data } = await axios.get('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY');
return data;
};
const IPDataComponent = () => {
const { data, error, isLoading } = useQuery('ipData', fetchIPData);
if (isLoading) return <span>Loading...</span>;
if (error) return <span>Error: {error.message}</span>;
return <div>{JSON.stringify(data)}</div>;
};
export default IPDataComponent;
import React, { useEffect, useState } from 'react';
import axios from 'axios';
const App: React.FC = () => {
const [ipData, setIpData] = useState(null);
useEffect(() => {
axios.get('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY')
.then(response => setIpData(response.data));
}, []);
return <div>{JSON.stringify(ipData)}</div>;
}
export default App;
$data = json_decode(file_get_contents('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY'));
var_dump($data);
import requests
response = requests.get('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY')
print(response.json())
require 'json'
require 'open-uri'
data = JSON.parse(open('https://ip-api.io/api/v1/ip/?api_key=YOUR_API_KEY').read)
puts data
Using Provided IP
This method is suitable for backend implementations, providing a specific IP address to retrieve its information.
const request = require('request-promise');
request('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY')
.then(response => console.log(JSON.parse(response)))
.catch(err => console.log(err));
$.getJSON('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY', data => console.log(data));
import axios from 'axios';
axios.get('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY')
.then(response => console.log(response.data));
fetch('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY')
.then(response => response.json())
.then(data => console.log(data))
.catch(err => console.error(err));
import { useQuery } from 'react-query';
import axios from 'axios';
const fetchIPData = async () => {
const { data } = await axios.get('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY');
return data;
};
const IPDataComponent = () => {
const { data, error, isLoading } = useQuery('ipData', fetchIPData);
if (isLoading) return <span>Loading...</span>;
if (error) return <span>Error: {error.message}</span>;
return <div>{JSON.stringify(data)}</div>;
};
export default IPDataComponent;
import React, { useEffect, useState } from 'react';
import axios from 'axios';
const App: React.FC = () => {
const [ipData, setIpData] = useState(null);
useEffect(() => {
axios.get('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY')
.then(response => setIpData(response.data));
}, []);
return <div>{JSON.stringify(ipData)}</div>;
}
export default App;
$data = json_decode(file_get_contents('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY'));
var_dump($data);
import requests
response = requests.get('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY')
print(response.json())
require 'json'
require 'open-uri'
data = JSON.parse(open('https://ip-api.io/api/v1/ip/1.2.4.5?api_key=YOUR_API_KEY').read)
puts data
Email Validation API Endpoints
Validate Email Address
Email Validation API Response Format
The API returns a JSON object with the following structure for email validation:
{
"email": "johndoe@email.com",
"is_disposable": false,
"syntax": {
"domain": "email.com",
"username": "johndoe",
"is_valid": true,
"error_reasons": ["NONE"]
}
}
Email Validation: Code Examples
This method demonstrates how to use the email validation endpoint to verify email addresses.
const request = require('request-promise');
request('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY')
.then(response => console.log(JSON.parse(response)))
.catch(err => console.log(err));
$.getJSON('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY', data => console.log(data));
import axios from 'axios';
axios.get('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY')
.then(response => console.log(response.data));
fetch('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY')
.then(response => response.json())
.then(data => console.log(data))
.catch(err => console.error(err));
import { useQuery } from 'react-query';
import axios from 'axios';
const fetchEmailData = async () => {
const { data } = await axios.get('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY');
return data;
};
const EmailDataComponent = () => {
const { data, error, isLoading } = useQuery('emailData', fetchEmailData);
if (isLoading) return <span>Loading...</span>;
if (error) return <span>Error: {error.message}</span>;
return <div>{JSON.stringify(data)}</div>;
};
export default EmailDataComponent;
import React, { useEffect, useState } from 'react';
import axios from 'axios';
const App: React.FC = () => {
const [emailData, setEmailData] = useState(null);
useEffect(() => {
axios.get('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY')
.then(response => setEmailData(response.data));
}, []);
return <div>{JSON.stringify(emailData)}</div>;
}
export default App;
$data = json_decode(file_get_contents('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY'));
var_dump($data);
import requests
response = requests.get('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY')
print(response.json())
require 'json'
require 'open-uri'
data = JSON.parse(open('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY').read)
puts data
val result = URL('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY').readText()
println(result)
import java.net.*;
import java.io.*;
public class Main {
public static void main(String[] args) {
try {
URL url = new URL('https://ip-api.io/api/v1/email/example@example.com?api_key=YOUR_API_KEY');
BufferedReader in = new BufferedReader(new InputStreamReader(url.openStream()));
String inputLine;
while ((inputLine = in.readLine()) != null)
System.out.println(inputLine);
in.close();
} catch (Exception e) {
e.printStackTrace();
}
}
}
use std::net::TcpStream;
use std::io::{self, Read, Write};
fn main() -> io::Result<()> {
let mut stream = TcpStream::connect('ip-api.io:80')?;
stream.write_all(b'GET /api/v1/email/example@example.com?api_key=YOUR_API_KEY HTTP/1.0\r\n\r\n')?;
let mut response = String::new();
stream.read_to_string(&mut response)?;
println!(response);
Ok(())
}
Rated 5 out of 5 stars by our customers!
Companies from across the globe have had fantastic experiences using the service.
Here's what they have to say.
IP-API.io has been a game changer for our global e-commerce platform. We now offer localized pricing without any hassles.
The accuracy and reliability of IP-API.io have helped us enhance our security measures and prevent unauthorized access effectively.
Amazing! Thanks so much for the speedy response. I have really enjoyed using IP-API.io!
Hi guys, I really like your way to support customers. Fast and you keep your word. Keep moving guys! Cheers.
YOUR SERVICE IS AWESOME! NICE WORK! THANKS! I LOVE YOU GUYS.
Dear IP-API.io Team, Thanks for the awesome service!
I have tried many geolocalization API's and this is the best one both in stability and in accurate results.
Great project! Super API, the best I have used so far.
Pricing
Start using IP-API.io to make your website safer and more user-friendly. Keep out unwanted bots, show visitors content that's relevant to where they are, and spot risky IP addresses quickly. It's perfect for making online shopping more personal and keeping your site secure. Get started today with one of the plans!
Small
Medium
Large
Need support?
Explore how IP-API can enhance your security, provide robust bot protection, and improve IP geolocation accuracy for your applications.
Contact SupportNeed more queries?
Customize your experience with tailored plans that fit your IP security and geolocation needs.
Email Us