IP Adress => Country & Provider


It would be nice to have the correct IP to Country & Provider conversion.

This could be done with (e.g. France) :

=> France Telecom (= Orange for french people)

This to prevent for example people that have US Opérating system (XP USA) living in France, appearing : country USA.

Ready to help building the database if needed,

Thanks for the great work


Well, just use the GeoIP plugin.

Well, thanks for the answer :slight_smile:

I did, found out that this is third party, going to be integrated in Core (?)

Nevertheless, IP is the second source for providers…

“In the Providers report, what does “IP” mean?
Piwik uses a special php function (gethostbyaddr) to request the hostname associated to a given IP. For example, the function would return “br76.comcast.net” and Piwik would categorize the visitor as using the provider “Comcast”.
Sometimes however, for specific IPs or when the function times out, Piwik doesn’t know which provider the visitor is using, and will simply report “IP”.”

=> therefore, even though country is ok, provider would be better…

gethostbyaddr only gives you the provider if it is given, not all the time…

=> adress ranges narrows the search, dont you think so ?

Maxmind free Data is inaccurate, wouldn’t be so bad if it was just a little inaccurate, but its beyond that after comparing its data with other databases online, but hey, it’s free and so is Piwik! Any alternatives to Maxmind data? I would look hard for an alternative before implementing it in Piwik core though…


The new plugin being developed currently has support for Cloudflare, IP2Location.com, IPligence, MaxMind, and Quova, as data sources, and a variety of methods (e.g., database/data file vs web service).

The free data from db-ip.com seems to be the most accurate for the places I’ve tested

Good news: GeoIP is now integrated in Piwik, enabling Accurate Visitors Geolocation in your Analytics reports. To enable GeoIP go to the Settings > Geolocation admin page, and follow the short instructions.

You can also get an even more accurate Country & City Database from here to enjoy top accuracy in detecting your visitors locations.

See also the documentation about Geolocation - Analytics Reports in Piwik.

What about Local IP address? We have some tracking happening on the LAN and these local network IP addresses are not in the GeoIP databases. Can we add them to the database or tell Piwik and override for that range?

Hey local ip is the address of the physical machine or address of the local network .
We can use the public IP to over ride by providing its range. Our public IP address can be viewed at Ip-Details.com . It finds the country of ISP and its geo-location . We can also check other IP addresses and its location using the search bar.

Just following up on this topic.
Any ideas how to do Geo Tracking for Local WAN IP Addresses?

I know what location (country, city) most of our WAN IP address are and would love to have Piwik track those along with all the Internet Traffic. An interface to override the GeoIP db or update the db with our custom IP and Geo data would be very helpful.

PLease contact Pro Services for such request : http://piwik.org/consulting/

Thanks for the suggestion.

I beleive we can’t be the only place in need of this functionality. I belive this to a common need when tracking occurs both internally and publicly. Thus why I am suggesting this for a feature enhancement.