How to test the pricing zones

In this article, you’ll review the following:

  • Understand when WooCommerce uses geolocation to determine the customer’s country.
  • Verify if the Price Based on Country plugin works.
  • Run a geolocation test using a VPN.
  • How to use the test mode to run tests.

Learn about how WooCommerce determines the customer’s country

“Price Based on Country” displays the pricing and currency for the customer country, so let’s familiarize how WooCommerce gets the customer country when geolocation is active:

  • If the user is logged in, WooCommerce gets the customer country from the user account.
  • For known users, WooCommerce gets the customer country from the session cookie. A known user is a user who added an item to the cart.
  • In any other case, WooCommerce uses the user’s IP to guess his country.

Checking if Price Based on Country is working fine

The best way to check the plugin works properly is by using the checkout page. To run a test on the checkout page, do the next:

  1. Add a product to the cart.
  2. Go to the checkout page and uncheck “Ship to a different address?
  3. Change the billing country. The price of the product should change according to your settings.
Note: If the product price on the checkout page is ok, the plugin is working correctly

Testing the geolocation using a VPN

Take a moment to review how to configure the WooCommerce geolocation before running tests.

A VPN service allows you to visit your store from different locations. There are a lot of VPN services available from which you can choose, but, in most cases, you can use a free service like TunnelBear.

TunnelBear Chrome extension

TunnelBear is user-friendly, easy to set up, and works across various devices, including Windows PCs, iPads, iPhones, and Android devices. TunnelBear service still covers more than 20 countries and can be used with up to five devices per account.

To test with a VPN software like TunnelBear, follow the next steps:

  1. Install TunnelBear or other VPN software :)
  2. Clear your browser history (cache and cookies)
  3. Close your browser.
  4. Open your browser and connect TunnelBear, and select the country you want to test.
  5. Check your “IP country” at If the country doesn’t match, wait and try again later.
  6. Visit your site.

To test another country you have to repeat the step from 2.

Run tests using the Test mode

The test mode allows checking how your prices look for a specific country without a VPN. To enable the test mode go to WooCommerce > Settings  > Pricing zones > Options. After enabling it, you have to select the country you want to test in the Test country drop-down.

The test mode overrides the geolocation by IP.

After enabling this option, you test by visiting the site in a new incognito (private) window to avoid to WooCommerce using the address stored in the cookies.

Note: You must close all incognito windows before doing each test.

Open link in incognito window - chrome

See also: