How do I use my own Mapbox or Google Maps key in the store locator?
You do not need a key: the map in One Stop Store Locator & Maps works without one. If you already use Mapbox or Google Maps, open Settings and paste your Mapbox public token under Mapbox, or your Google Maps API key under Google Maps. Then pick one of their styles in Appearance, under Map style: seven Mapbox styles, or Google Maps. Turn on Use for search suggestions and the search box suggests places from the same provider as customers type. The provider bills that usage to your own account, and a key that does not work falls back to the default map.
Steps
- Create the key in your provider’s account. For Mapbox, a public token, which starts with pk. For Google, an API key with the Map Tiles API enabled, plus the Places API (New) if you want search suggestions. Restrict the key to your store’s domain.
- In the app, open Settings.
- Under Mapbox, paste the token into Mapbox public token. Under Google Maps, paste the key into Google Maps API key. Use Mapbox and Use Google Maps switch each provider on or off.
- Save with the save bar. The Settings menu shows a check mark next to the provider once the key is ready.
- Open Appearance and, under Map, pick the provider’s style in Map style: Streets, Outdoors, Light, Dark, Satellite streets, Navigation day or Navigation night for Mapbox, or Google Maps.
- Optional: back in Settings, turn on Use for search suggestions under the same provider. Suggestions run while that provider’s map style is selected.
- Check the live preview in Appearance, then the locator on your storefront.
What to watch out for
- The provider bills the map and the suggestions to your own account, and its logo shows on the map.
- Mapbox suggestions show only with a Mapbox map style, and Google suggestions only with Google Maps. With another style, the search box suggests your store names, and US ZIP codes and cities when Suggest places as customers type (US only) is on.
- If the key stops working, or the provider is switched off in Settings, the locator falls back to OpenFreeMap, and Map style marks your saved style as off in Settings.
- Switching a provider off keeps the key, so you can switch it back on later.