How to Password Protect WooCommerce Categories

No doubt, WooCommerce is the most versatile eCommerce platform in the web development industry. You can use WooCommerce to develop just about any type of eCommerce experience imaginable.

WooCommerce product categories are no different, & in this post, we are going to show you how to use a plugin that lets you keep WooCommerce categories hidden by locking them with passwords.

Password protected product categories isn’t a prominent feature among WooCommerce stores, nor is it a default option of WooCommerce, but you would be amazed by how useful it can be.

Whether you need to sell wholesale products to a specific group of users, create members-only products or even make free products available to users after they complete specific actions, this is one of those unique features that can have a significant impact on your company’s business strategy.

What are WooCommerce Protected Categories?

A WooCommerce protected category means that a user can’t access specific categories or their products unless the user has the correct & proper permissions. This category is also known as a private or restricted category.

In any case, a protected category means that to have access to WooCommerce; the user must either:

  • Enter a password
  • Be logged in
  • Have a specific user role

Why Should You Password Protect WooCommerce Categories?

The question here is why you would want to password protect WooCommerce categories? There are plenty of situations where you need to password protect WooCommerce categories, and here are some of them.

  • Wholesale stores: If you are working as a wholesaler, you probably don’t want your prices & products list publicly available, so password protection helps in restricting access to only authorized shoppers.
  • Private client areas: You can create separate categories for individual clients to sell a unique product to each client.
  • Members-only store: With the help of password protected categories, you can create an entire store that’s only available to members.
  • Mix-and-match: You can leave most of your store “public” like normal, but password protects some restricted products that you don’t want everyone to be able to see.

What WooCommerce Password Protected Categories does?

WooCommerce Password Protected Categories is a plugin that helps you to add password protection to one or more of your WooCommerce product categories. It might seem pretty simple to some, but actually, there’re a lot of things behind WooCommerce Password Protected Categories.

  • Each product in the category is also password protected, in case someone gets their hands on a direct link to a product.
  • You have the option to completely hide your password protected categories or still have them publicly listed.
  • Once a customer enters his password, all the products in that particular category are automatically unlocked – there is no need to re-enter the password.
  • You can use a single sign-in page for all your customers. They will automatically be taken to the relevant category based on the password that they enter.

Doesn’t WooCommerce Provide You with This Facility?

The answer is “Not really”, you can add a password to individual WooCommerce products with the help of core WordPress Visibility control.

password protected categories

That’s perfect if you need to restrict access to a single product. But it is not solving the same problem that WooCommerce Password Protected categories plugin solves because:

  • There’s no single sign-on option.
  • You need to restrict each product individually, which is quite hectic if you start getting into 10+ products.
  • You can use only a single password for every product, rather than giving each person a unique password.

Importantly, WooCommerce Password Protected Categories provides a solution that’s more flexible and less time-consuming.

How WooCommerce Password Protected Categories Works?

From the above discussion, you get an idea of what WooCommerce Password Protected Categories helps you do. But how does it work on a WooCommerce store? So, let’s find the answer.

After installing and activating the plugin, the first and foremost that you will want to do is configure some basic settings.

WooCommerce Password Protected Categories Basic Settings

You can access the plugin’s settings by going to WooCommerce > Settings > Products > Password Protected Categories. Here’s everything that this plugin helps you configure.

password protected WordPress basic settings

  • Category Visibility: Choose whether or not to display password-protected products/categories in your store and your navigation menus.
    category visibility
  • The Password Expires After: You can choose how many days the category will remain unlocked after a user enters the password.
  • Category Prefix: Add a “Private” designator before a category on the category page & in menu items.
  • Client Login Page: Designate a single sign-in page for your clients.

Note: You can use a different password for each person & they will be automatically redirected to the relevant category.

Password expiration

By this way, you can also configure the text & styling of your Password Form.

Style password form

How to Password Protect WooCommerce Categories

Once you have configured the plugin’s basic settings, it’s time to start restricting some categories. To restrict categories, you need to go to the actual WooCommerce product category area (Products > Categories).

Now when you edit an existing category or create a new category, you will get a new Visibility option.

visibility option

If you select the password-protected option, you will be able to add one or more passwords for the category (you can also set the private option to make categories private).

The ability to add multiple passwords is useful because it helps you give each client or user their password. To add a password, all you need to do is to click the Plus icon.

plus icon

Once you are finished adding passwords, you can save your changes to start password protecting the category.

What it Looks Like to Visitors Trying to Access a Protected Category

Now that you have password protected a category in WooCommerce, anyone who tries to access it will see something like this on his screen.

login screen

Note: You can customize this form with the help of text & CSS styling.

Once you enter a valid password, you will be able to browse the category & all its products like normal. You can also opt to create a single sign-in page for all your customers.

How to Hide Protected WooCommerce Categories from Search Engines

There’s no proper way to hide protected WooCommerce categories or products from search engines. However, you can use the “Yoast SEO” plugin to set individual product categories to “noindex” to prevent them from being indexed, which should prevent them from appearing in search engines.

Hide protected categories from search engine

You can hide protected WooCommerce Categories by navigating to Products > Categories > Edit Category (for whichever password-protected category you want to hide from search engines) > Yoast SEO Meta Box > Settings.

And then select ‘No’ for the setting labelled “Allow search engines to show this category in search results?”

Password Protect WordPress (PPWP) Pro

Alternatively, our Password Protect WordPress Pro and its Access Levels extension also offer you the functionality to password protect WooCommerce categories. Once you password protect certain categories, all products belonging to them will be automatically protected with the same password as well.

What’s more, the same protection will apply to new posts created for products in a protected category. In case you want to restrict WooCommerce categories to certain users, you can set up access levels for different product categories too. Users with passwords of higher level categories will be able to unlock lower level ones with ease.

Final Thoughts

Those are some basic things about password protected WooCommerce categories & using WooCommerce Protected Categories. And if you want to protect your entire WooCommerce store, Password Protect WordPress Pro has just the right feature.

WooCommerce Protected Categories is available for only $89/year for a single site license, $159/year for up to 5 sites and $319/year for up to 20 sites. So, what are you waiting for? Grab this plugin today, or check out their demo if you are still not sure.