GeoIP files from MaxMind
Creating a MaxMind account, downloading GeoLite2 City and ASN, putting the files in place, keeping them current, and the licence terms.
GeoIP files turn a visitor's IP address into a country, region, city and network (ASN). They feed the site analytics and the country of each payment. The platform reads the files with its own reader; no extension or library is needed, and IP addresses are never sent anywhere.
1. Create a MaxMind account#
Sign up for a free GeoLite account at maxmind.com and accept the GeoLite2 End User License Agreement. GeoLite data is free, with attribution: the platform's analytics pages already credit MaxMind.
2. Download the databases#
Account → Download Databases. Download, in MaxMind DB (.mmdb) format (the GZIP download contains the .mmdb file):
- GeoLite2 City (about 60 MB) — country, region, city;
- GeoLite2 ASN — network operator.
3. Put them in place#
Either:
- Upload them on Super → GeoIP. Each file is checked before it is used: it must open, be a City, Country or ASN database and answer test lookups. Uploads are audited and copied to the other server of a pair automatically; or
- copy them into
data/geo/on the server (ownerwww-data), when the City file is larger than PHP's upload limit.
Every *.mmdb in data/geo/ is considered. For each kind, the newest build wins; older files stay listed as not used and can be deleted.
4. Keep them current#
MaxMind publishes new builds twice a week, and its licence asks you to keep the data reasonably current. The GeoIP screen and the self-check warn when the active City file is older than 60 days. A simple routine: download and upload the two files once a month.
When you stop using the data, delete the files, as the licence requires.