This is a guide to show you how to hide product prices by zip code in WooCommerce.
Once you configure this restriction by zip code, customers from the selected zip codes will not view the product prices on your store.
You’ll be able to hide all product prices by zip code, as you see in the screenshot below:
And you’ll also be able to hide product prices in specific products only:
We will do this with the WooCommerce Product Restrictions by Location plugin. It allows you to restrict your products, variations, categories, attribute pages, and discount coupons by zip, city, state, province, store location, and using custom locations.
In this case, it will allows you to hide product prices by zip code. Your customers will still be able to add the products to the cart, place the order, etc. However, they won’t see the prices on the store and product pages.
You can download the plugin here:
Download WooCommerce Product Restrictions by Zip Code Plugin - or - Read more
You need to follow these simple steps after installing and activating the plugin to hide prices by zip.
Start by setting up the zip code restriction method
First, we need to select what we will restrict, and how we will restrict it.
Go to WooCommerce > Settings > Restrictions by location.
Once there, select the following values to set up the zip code restriction method:
- I want to restrict: Products and variations
- I want to restrict by: Zip code
- What happens when the user location is unknown: You can show or hide all the products in your store.
- Save changes
Option 1: Hide all WooCommerce prices by zip code
You can hide all the prices from your WooCommerce products by zip code. In this case, you’ll apply a global restriction.
Go to Products per location in the plugin’s global settings, and select the following values:
- Products per location: You need to first, enter the zip codes separated with commas, or entering a new zip code in each line.
- Sell in selected locations: No. In this case, you’ll still sell the products, this value is to enable the prices by zip restriction only.
- What happens when a customer location is restricted: Tick the Hide product reviews checkbox.
- Save changes
Once you apply these changes, no products in your store will show the prices when a customer enters a selected zip code. Product prices will be hidden in the store and the product pages.
Option 2: Hide prices by zip code for specific products
You may want to not hide all WooCommerce products, and instead, hide prices by zip codes for specific products.
In this case, you need to edit the products individually, but first, you need to select these values in the Products per location tab on the plugin’s general settings.
- Products per location: Don’t add any zip code here, because the zip codes will be selected in each product.
- Sell in selected locations: No. In this case, you’ll still sell the products, this value is to enable the prices by zip restriction only.
- What happens when a customer location is restricted: Tick the Hide product reviews checkbox.
- Save changes
Now you need to go to WooCommerce > Products and open a product for which you want to hide the price by zip code.
Once you open the product you’ll edit, go to Local restrictions in Product data and select the following values:
- Zip codes: Enter all the zip codes that won’t see the zip codes.
- Available in selected locations: No
- Update the product.
This is how you can easily hide product prices by zip code. We also have tutorials on how to hide prices by city and by state or province.
WooCommerce Product Restrictions by Location allows you to easily restrict your WooCommerce products by zip code, location, city, state, store location, or any other custom location.
You can download the plugin here:
Download WooCommerce Product Restrictions by Zip Code Plugin - or - Read more