Though you are in business with eCommerce website, but sometimes you don’t want to sell your products to anyone. For that you want to protect your products categories and only allowing certain customers to purchase them. Hope, this article will be helpful for them, because we’ll give the step by step guideline how to create a private categories in WooCommerce.
Why to create WooCommerce private categories?
There are several reasons to create private categories in WooCommerce. Some reasons are:
- For wholesales products only: Sometimes you need to create a private categories of wholesales products only, that will have certain users access.
- Special set of products for members only: You can create private categories for members only. If you are running a membership site and want to give offer a special set of products for members only.
- For your own niche products: For your own niche products sometimes you need to create a private categories.
- For age restricted sites: Sometimes you may require to verify the age of your customers before they can purchase your products. Creating private categories is the perfect way to prevent any non-verified users from making unauthorized purchases.
How To Create a Private WooCommerce Category
To create a private WooCommerce category you have to purchase and install WooCommerce Members Only plugin. This plugin gives you the ability to hide all products and store content, or just products in certain categories.
After successful installation and activation of plugin go to WooCommerce > Settings > Members Only for configuring the settings.
There is no complicated settings here in this plugin. It is very simple that anybody can configure this within a minute.
In restricted method you will get the following option:
- Log In Status – users need to be logged in to access the restricted content
- Password – users need to enter a password to access the restricted content
- User Role – users need to belong to a specified user role to access restricted content
How to Define Which Categories Are Private?
You can define which categories are private. Under ‘Restricted Content’ just select ‘Specified categories’ then in the ‘Restricted categories’ field enter the categories that you want to make private.
That’s it, you have successfully created private categories.
How to hide protected products in Archives?
When you want to create a private categories you may think two options:
1. Completely invisible to users
2. Visible but not accessible
If you put tick on the ‘Hide Products in Archive’ option then you’ll make private categories completely invisible, meaning that all reference to them will be removed for users who are restricted. So, the shop pages, all archive pages, and product pages will not be visible. This is useful if your private products should not be discover able by every user to the site, for instance if you have a private category for staff-only products then you probably wouldn’t want this to be visible to your normal customers.
How to remove a private category?
If you’ve chosen to make your private categories totally invisible from any unauthorized users, then you can hide any reference to those categories from your site menus. To do this, just enter the names of the site menu item in the ‘Exclude from Menu’ field. These site menu items will be hidden from any users who don’t have permission to view the private categories.
How to choose Widget Whitelist
If you have widgets on your site that refer to private categories. By using the ‘Widget Whitelist’ setting, you can decide which widget can still be displayed to users. For example, the search widget which you would want to make available to all users.
To make use of this feature, just enter the names of widgets that you want to show to all in the ‘Widget Whitelist’ field. You can find the widgets names by going to Appearance > Widgets.
If you want to create a private WooCommerce categories, hope this plugin will be helpful for you.
You may also like: Best Multi-vendor Plugins: Dokan vs WC Vendor vs WC Marketplace