Local geolocation database

What are local databases for?

If you don't want to use our API because you prefer to have an in house solution or because it results too expensive for your projects you can still use our plugins with a database installed in your server. For that you need to have an active subscription.

Because you are using a local database you won't be consuming requests. Baby plan includes 1 local database which means you can use it on 1 site only. But, you still have 10k requests to use on unlimited sites and both can be used together.

Local database it's the perfect solution for country geolocation where you don't need much accuracy because any free database will geolocate 99% of countries by ip address.

Requirements:

You need to have an active GeotWP subscription in order to make the plugins work with your own database. If you don't have one visit your account before continuing.

Depending on your plan you will have one or more local databases available. You will need to whitelist each site in the local databases domain field. Please follow all the common settings (Api keys, whitelist domain, etc) to make the plugin work.

Installing Databases

Once you did all the requirements you are ready to install and active the database. Depending on which provider you choose you need to follow certain steps.

Geot Maxmind

Download Geot Maxmind plugin from your account page. The plugin will automatically download and update the Maxmind geolite free database for you.

In order to make it work you will need a maxmind license key

Create an account with Maxmind
  • Create an MaxMind Geolocation account
  • On the registration page, complete the form with your information. If you’re not sure what to choose as “Industry” and “Intended use” fields you can fill as “Content delivery” and “Content customization” respectively.
  • After submitting you’ll get an email with a link to set your password shortly. Click on that link and choose a password.
Obtain the Maxmind Key
  • Go to: https://www.maxmind.com/en/account
  • Select the “Manage License Keys” tab in your user account dashboard.
  • Click on “Generate new license key”.
    • Add a description (just as the name of your site)
    • Choose “No” next to “Will this key be used for GeoIP Update?”
    • Select “Confirm”.

They key is shown just once, copy it, and paste it in the plugin settings page.

  • Go to: GeotargetingWP > Settings > Maxmind
  • Paste the license key
  • Select “Save changes”

Lastly refer to activate database section to proceed.

Maxmind users

For premium Maxmind database you need to download the city database and unzip it. Then name the file GeoLite2-City.mmdb and place it in the following path

wp-content/uploads/geot_plugin/GeoLite2-City.mmdb

Remember to update your database regularly to keep accuracy as much as possible.

Lastly refer to activate database section to proceed.

Kinsta users

Simple contact Kinsta hosting support department and ask them to enable GeoIp for your account. Depending if you are targeting countries, states or cities they will enable the correspondent cache bucket for you.

Lastly refer to activate database section to proceed.

WP Engine users

Simple contact Wp Engine hosting support department and ask them to enable GeoIp for your account. Depending if you are targeting countries, states or cities they will enable the correspondent cache bucket for you.

Lastly refer to activate database section to proceed.

IP2Location users

For IP2Location you need to name the file IP2LOCATION.BIN and place the file in the following path:

wp-content/uploads/geot_plugin/IP2LOCATION.BIN

Remember to update your database regularly to keep accuracy as much as possible.

Lastly refer to activate database section to proceed.

Activate Database

Once you installed the database you need to go to GeotargetingWP -> Settings and check the box for the new setting field that just appeared. The plugin will detect which database you installed, and you simple need to check the box to make it live.

enable database

Change filename or location

You can change the default location and file name using one of the following php filters:

geot/mmdb_path

geot/ip2location_path

For example to change the location and filename of Maxmind you can do the following in your functions.php

add_filter( 'geot/mmdb_path', function(){ return WP_CONTENT_DIR . '/database/GeoLite2.mmdb';} );

Check out our WordPress geolocation solutions
to find out everything you can do!

Start your free trial