IP Geolocation MCP Server
Summary: This MCP server exposes ipinfo.io IP intelligence to AI agents — geolocation, ASN/ISP data, privacy detection, and map generation.
Look up your own IP —
ipinfo_lookup_my_ipgeolocates the calling client's IP (on stdio, the server's outbound IP); takes no arguments.Batch IP lookup —
ipinfo_lookup_ips(ips, detail)returns per-IP records in input order, up to 1,000 IPs per call;detail="summary"omits heavy nested blocks,detail="full"returns everything.Rich per-IP fields — city/region/country, lat/long, timezone, hostname, ASN, org, privacy flags (VPN/Tor/proxy/relay/hosting), plus plan-gated carrier, company, domains, and abuse contacts.
Aggregate large batches —
ipinfo_summarize_ips(up to 500,000 IPs) returns counts/percentages by country, continent, ASN, and privacy flags, with top-N buckets and mapped/skipped/failed counts.Residential proxy detection —
ipinfo_check_residential_proxy(ip)classifies known residential-proxy exit nodes (requires Enterprise add-on; otherwiseauth_insufficient_scope).Map generation —
ipinfo_generate_map_url(ips)builds an interactive ipinfo.io map for up to 500,000 IPs, reporting mapped count, skipped IPs with reasons (capped at 100), and a truncation flag.Robust error handling — failures raise JSON-encoded
ToolErrorenvelopes with stable codes,temporaryflag,retry_after_ms, repair hints, and request IDs; invalid/special-use IPs are filtered with warnings.Safe by design — all tools are read-only, idempotent, and open-world; missing tokens fall back to the free Lite tier.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@IP Geolocation MCP Server where is 8.8.8.8 located?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
IP Geolocation MCP Server
This project is deprecated and no longer maintained. IPinfo now provides an official MCP server at https://mcp.ipinfo.io. Please use that instead. This repository is archived, and the final release is v0.7.1.
A Model Context Protocol server that exposes the ipinfo.io API to AI agents. Geolocate IPv4 and IPv6 addresses, identify ISPs and ASNs, detect VPN/proxy/Tor exit nodes, and generate interactive maps for sets of IPs.
Installation
Sign up for a free IPInfo API token at https://ipinfo.io/signup if you don't have one. The server runs with no token (free Lite tier — country and ASN basics) but most fields require a token.
Claude Desktop (one-click bundle)
Download the .mcpb bundle from the latest release and open it to install in Claude Desktop. You can set your IPINFO_API_TOKEN (and optional cache tuning) in the install dialog; leave the token blank to run in the free Lite tier. The bundle launches the server with uv, so uv must be installed and on your system PATH (GUI apps don't inherit your shell's PATH).
Other MCP clients
Most MCP clients accept the following values:
Field | Value |
Command |
|
Arguments |
|
Environment |
|
Development Version
To run the latest from main:
Field | Value |
Command |
|
Arguments |
|
Environment |
|
Related MCP server: GeoIP MCP Server
Tools
ipinfo_lookup_my_ip()— Geolocate the calling client's own IP. Takes no arguments. On stdio transports the result reflects this server's outbound IP, not the end user's.ipinfo_lookup_ips(ips, detail="summary")— Geolocate one or more specified IPs. Defaults todetail="summary", which omits heavy nested blocks (continent, flags, currency, abuse, domains) for batch token savings; passdetail="full"for every field. Capped at 500,000 IPs per call. Invalid or special-use addresses (private, loopback, etc.) are filtered withctx.warning()and excluded from the result list, as are IPs that fail upstream — match returnedIPDetails.ipvalues back to your input to detect what was dropped. If every attempted lookup fails, a temporaryapi_erroris raised.ipinfo_summarize_ips(ips, group_by=("country", "asn"), top_n=50)— Geolocate and aggregate a batch into fixed-size counts and percentages by country, continent, ASN, and/or privacy flags. Use this for large log-analysis tasks where per-IP records would waste context. Returns mapped, skipped, and failed counts plus capped top-N groups.ipinfo_check_residential_proxy(ip)— Check whether an IP is a known residential-proxy exit node. Taggedenterprise— requires the IPInfo residential-proxy add-on.ipinfo_generate_map_url(ips)— Build an interactive ipinfo.io map for a set of IPs. Returns aMapResultwith the URL, the count that made the map, the IPs filtered out (with reasons, capped at 100), and atruncatedflag.
Plan tiers
Tier | Fields available |
Free Lite (no token) | country, country_code, continent, ASN basics |
Core | full geolocation, ASN details, privacy/VPN/proxy/Tor/hosting flags |
Plus | adds carrier and company data |
Enterprise | adds domains and abuse contacts |
Residential-proxy add-on | enables |
Errors
Every tool raises a ToolError whose message is a JSON-encoded envelope with a stable code (invalid_ip_address, special_ip_unsupported, no_valid_ips, too_many_ips, auth_invalid, auth_insufficient_scope, quota_exceeded, timeout, api_error, unknown_error), a temporary flag, optional retry_after_ms, a repair hint, and a request_id correlation id. Agents should parse the message as JSON and branch on code. Each tool also advertises the subset of codes it can raise via meta.error_codes, so you can see the branch set from tool introspection.
Configuration
Environment Variables
Variable | Description | Default |
| IPInfo API token. Without it the server runs in free Lite mode. | unset (Lite) |
| Per-IP cache TTL in seconds. Cached results retain their original |
|
| Maximum cache entries before oldest-first eviction. |
|
License
MIT License — see LICENSE. Release history in CHANGELOG.md.
Disclaimer
This project is not affiliated with IPInfo.
Available Tools
5 toolsipinfo_check_residential_proxyCheck Residential ProxyARead-onlyIdempotent
Classify whether an IP is a known residential-proxy exit node.
Returns ResidentialProxyDetails with is_residential_proxy (the canonical
yes/no), and — when true — service, last_seen (YYYY-MM-DD), and
percent_days_seen over a 7-day window. Useful for fraud, bot, and
ad-fraud detection. This is distinct from the general privacy flags on
ipinfo_lookup_ips (VPN / Tor / open web proxy / hosting): use this tool
only to detect residential-proxy networks that route traffic through real
residential IPs. Requires IPINFO_API_TOKEN with the Enterprise
residential-proxy add-on; absence surfaces as auth_insufficient_scope
(distinct from auth_invalid for a missing/wrong token).
Inputs: ip (required). Returns: Residential proxy detection information. Identifies whether an IP is part of a…
ipinfo_generate_map_urlGenerate IP Map URLARead-onlyIdempotent
Build an interactive ipinfo.io map for a set of IPs.
Returns MapResult{url, mapped_ip_count, skipped_ips, skipped_count,
truncated}. skipped_ips is a list of {ip, reason} entries for filtered
inputs, capped at 100; truncated flags overflow. skipped_count is the
true total even when the list is capped, so mapped_ip_count + skipped_count equals the input length. Errors raise ToolError with a
JSON-encoded envelope.
Inputs: ips (required). Returns: Structured response from ``ipinfo_generate_map_url``. Replaces the bare-URL str…
ipinfo_lookup_ipsLook Up IPsARead-onlyIdempotent
Geolocate one or more IPs and return ISP/ASN details.
Returns a list in input order (after dedup and invalid-IP filtering); match
results back to your input via the ip field. IPs that fail upstream are
omitted and logged; if the batch resolves no IPs at all the failure is
raised rather than masked — auth_insufficient_scope when the upstream
returned nothing (token tier likely lacks /batch access; look IPs up one
at a time or upgrade to Core+), otherwise a retryable api_error. Defaults
to detail="summary" (heavy nested blocks
omitted); pass detail="full" for every field. Capped at 1,000 IPs per
call (too_many_ips above that): this tool returns one record per IP, so
for larger batches use ipinfo_summarize_ips (fixed-size aggregates) or
ipinfo_generate_map_url. Higher plan tiers populate more fields; see the
server instructions for the Lite/Core/Plus/Enterprise tier mapping. For
VPN/Tor/open-proxy/hosting detection read the privacy flags on each
record; for residential-proxy exit-node classification use the separate
ipinfo_check_residential_proxy tool. Typically completes in seconds;
bounded by a 120s tool timeout that surfaces as a timeout envelope.
Errors raise ToolError with a JSON-encoded envelope.
Inputs: ips (required), detail. Returns: result
ipinfo_lookup_my_ipLook Up My IPARead-onlyIdempotent
Geolocate the calling client's own IP. No arguments.
On stdio transports the result is this server's outbound IP, not the
end user's. Use ipinfo_lookup_ips when the caller already has a
specific IP. Errors raise ToolError with a JSON-encoded envelope.
Inputs: no named parameters. Returns: Comprehensive IP address information including geolocation, network, and metada…
ipinfo_summarize_ipsSummarize IPsARead-onlyIdempotent
Aggregate one or more IP lookups into counts and percentages.
Uses the same validation, deduplication, cache, and upstream batch lookup
path as ipinfo_lookup_ips, but returns fixed-size summary buckets instead
of per-IP records. This is the preferred tool for large log-analysis tasks
such as "where did visitors come from?" when the caller does not need the
underlying records. Percentages are based on mapped_ip_count; filtered
and failed IPs are counted separately. Errors raise ToolError with a
JSON-encoded envelope.
Inputs: ips (required), group_by, top_n. Returns: Fixed-size aggregate summary for a batch of IP lookups.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
Each tool performs a distinct function: residential proxy detection, map generation, IP lookup (batch), own IP lookup, and summary aggregation. Their purposes are clearly separated with no overlap.
All tools follow the consistent 'ipinfo_verb_noun' pattern (e.g., ipinfo_lookup_ips, ipinfo_summarize_ips), making the naming predictable and easy to understand.
With 5 tools covering geolocation, map visualization, and specialized proxy detection, the count is well-scoped for an IP geolocation service without unnecessary bloat.
The set covers core operations (lookup, self-lookup, batch, summary, map) and residential proxy detection. Minor gaps like WHOIS or IP range queries are absent but reasonable for the domain.
Maintenance
Related MCP Connectors
Official IPinfo MCP Server - IP intelligence tools for AI assistants
IPInfo MCP — wraps ipinfo.io (free tier, no auth required for basic usage)
IPStack MCP Adapter turns IPStack's REST APIs into Model Context Protocol tools so any MCP-compatible client can call them directly in conversation. The first release ships IPStack IP geolocation and security lookups (single IP, caller's IP, and bulk). Additional APILayer services are added by registering them in a single config file, so the catalog grows without client-side changes.
MCP server for IPv4 geolocation lookup with Chinese output, supports batch queries.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAn MCP (Multi-Agent Conversation Protocol) server that enables natural language interaction with the AbstractAPI geolocation service, allowing users to retrieve geographic information about IP addresses.-
- AlicenseNot gradedqualityDmaintenanceAn MCP server that provides IP geolocation services using MaxMind's GeoIP2 databases, allowing users to retrieve geographical information for single or multiple IP addresses including country, city, coordinates, and ASN details.GPL 3.0
- AlicenseBqualityDmaintenanceAn MCP server that provides access to the Netdetective API for querying information about IP addresses. It enables users to retrieve metadata for a specified IP address or the connecting client's default IP address.1MIT
- AlicenseNot gradedqualityFmaintenanceMCP server for IP geolocation lookups using ipinfo.io, with single, own, and batch queries.1MIT