Skip to content
Log in

Use geolocation to send customers to their correct store

On this page

Use geolocation when you run stores for different countries and want each visitor to land on the one that matches where they are. It reads the visitor’s IP address and redirects them to the store linked to their country, so they see pricing in their own currency, the products available to them, and shipping rates for their location.

If a visitor’s country has no store of its own, they are sent to the default store instead. See redirect behavior and the default store for how to set the Default checkbox on a Store record.

Before you begin

Enable geolocation

  1. Contact StoreConnect support to have geolocation enabled on your org.
  2. Open the Store record you want to link to a country.
  3. Set the Zone field to the zone covering that country.
  4. Save the record, and repeat for each regional store.
  5. Confirm one store has the Default checkbox selected.
  6. Visit the store from an IP address in one of your configured regions, or through a VPN, and confirm you are redirected to the matching store.

There is no further configuration. There is no geolocation object to change, and no Liquid or CSS code to edit.

What the customer sees

Following any initial auto-redirect, a customer who chooses to switch to a store outside their own country is not auto-redirected back. Instead they see a Region Selector bar at the top of the website telling them the store is out of their region, and prompting them to choose from the available stores.

The customer can pick a Store from the drop-down, which sends them there and stops showing the bar. If they visit another region after that, the bar appears once again. They are never auto-redirected back to the store they chose.

If they choose not to pick a Store, the Region Selector bar stays until they make a decision.

The purpose of the Region Selector bar is to make it clear to the customer that they are “out of region” (either their native one, or one they have selected) in case they arrived or navigated there by accident. Having them select a region from the bar:

  • confirms they’ve been notified that they’re out of region,
  • allows them to see and select a more relevant store
  • gives them a way to dismiss the notification

Examples

Two stores, Australia and the USA

You have built two stores, one for Australian and one for USA customers. They carry some overlapping and some country-exclusive products, and they have different tax behaviors, shipping methods, and currency. You want each customer to land on the store most relevant to them.

A visitor from Australia who opens the USA store is detected and redirected to the Australian store. A visitor from the USA who opens the Australian store is redirected to the USA store.

The customer purposefully switches to a store outside their region

The customer notices there is a Canadian store and switches to it.

A Region Selector bar appears at the top of the website indicating that they are accessing the site out of their region. It offers a drop-down list of the stores they can access and prompts the customer to pick one.

The customer is aware of this, but does not pick one. They continue to browse the Canadian store. The Region Selector remains at the top of the site, although the customer can close it if they wish.

The customer chooses a store region

A customer accessing the website from New Zealand lands on the store linked to the USA. Since there is no store set up for New Zealand, the customer is redirected to the default store.

The default store happens to be the USA store, so they end up on the same store they started on. This time, though, a Region Selector bar appears at the top of the site, offering a drop-down list of the stores they can access.

The customer picks the Australian store and confirms the selection. They are redirected to the Australian store, and the Region Selector does not show anymore.

Was this article helpful?

Was this article helpful?