Maps Marker Pro has a built-in geocoding framework which allows you to choose which geocoding provider to use. The default geocoding providers Algolia based on OpenStreetMap data are ready to use out-of-the-box without any additional configuration or mandatory API keys. If you want to use Google for geocoding though, you have to register for a Google Geocoding API key – related details and links about terms of usage, pricing and billing can be found here.
Terms of services
Google´s related Terms of Services can be found at https://developers.google.com/maps/terms.
Important update from Google regarding upcoming changes coming into effect on 11th June 2018:
“Geocoding is charged by request from Google, see the pricing table for details.”
If you enable Google Geocoding within Maps Marker Pro, the following 2 Google APIs will be used and the following minimum amounts will be billed by Google:
- “Autocomplete per character” with a minimum price of USD 2.83 for 1000 calls for up to 70.000 chars per month (pricing details)
- “Places Details” – Basic with a minimum price of USD 17.00 for 1000 calls for up to 11,000 calls per month (pricing details)
Those amounts will be offset with your $200 of free monthly usage – if you exceed those amount, you will be charged automatically by Google.
Tutorial: how to generate a Google geocoding key
This tutorial will show you how to create a Google Maps Geocoding API key (using this special server key has been supported since Maps Marker Pro v2.8/Leaflet Maps Marker v3.11).
We recommend to create a unique key for Google Geocoding only – even if you already registered a key for Google basemaps (as other best practises for securing your Google geocoding key against quota theft are needed, see below for details!)
Prerequisite: you must have a Google account to generate a key for key for Google Maps Geocoding API and Google Places API, which are both needed:
- Open the following link with your google account to activate the needed APIs for geocoding:
- Create a new project or select an existing project:
- Copy your Google API key to clipboard:
- Optional, but recommended to prevent quota theft: click on the link “API Console” below your API key and set an IP referrer for your key so that it can only be used on your domains.
Do not set “HTTP referrers (web sites)” restrictions as it is recommended for Google basemaps, this will cause Google Geocoding API to break!
– choose “IP addresses (web servers, cron jobs etc)” from “Key restrictions”
– enter the IP address of your server to “Accept requests from these HTTP referrers (web sites)” (your hoster may assist you in providing the IP address or range of your server):
Optional: Enable billing. See Usage Limits for more information.(billing is mandatory starting from 11th June 2018)
- Log in on your WordPress Admin and navigate to Settings > Geocoding > Google and paste the server key you copied earlier into the “Google API server key” field:
- Click the “Save Changes” button at the end of the settings page.
If you also want Google Geocoding to be your default geocoding provider, please navigate to Settings / Geocoding / Geocoding provider and change the option “Main geocoding provider” accordingly.
If you have trouble translating addresses into geographical locations, please verify that the Google Maps Geocoding API is enabled in the Google Maps API Manager.
Reference for all Google Geocoding settings
You may bias results to a specified circle by passing a location and a radius parameter. This instructs the Place Autocomplete service to prefer showing results within that circle. Results outside of the defined area may still be displayed. You can use the components parameter to filter results to show only those places within a specified country. If you would prefer to have no location bias, set the location to 0,0 and radius to 20000000 (20 thousand kilometers), to encompass the entire world.
The language in which to return results. See the list of supported domain languages. If you set a specific language at Settings / Google / “Google language localization”, that language will also be used for Google Geocoder. If no language is set, the current WordPress locale will be used.
Optional region code, specified as a ccTLD (“top-level domain”) two-character value. This parameter will only influence, not fully restrict, results from the geocoder. For more information see Region Biasing.
Optional component filters, separated by a pipe (|). Each component filter consists of a component:value pair and will fully restrict the results from the geocoder. For more information see Component Filtering.