Lots of people ask us how to create a WooCommerce hidden store. This tutorial covers 2 methods to build a private store using 2 plugins: WooCommerce Private Store and WooCommerce Protected Categories. It will also help you choose which WooCommerce hidden store plugin is best for your website.
You might want a public-facing website that anyone can access, with a hidden e-commerce area that only people with the right credentials can see. Or you might want to hide your entire WooCommerce store.
At the end of this tutorial, you'll know how to create a WooCommerce hidden store or temporarily hide a store.
Your categories, products and other WooCommerce content will not appear anywhere on your public website. They won't appear in the navigation menu, sidebar widgets or on your homepage. Read on to learn how, or watch the video:
1. Before you start
Once you have done this, you should add your WooCommerce products to their respective product pages in the usual way. You can also create the public pages of your website (if you're having one) such as Home, About and Contact.
Once you've done that, you're ready to hide products and transform your website into a hidden WooCommerce store.
2. Decide which WooCommerce hidden store plugin to use
First, you need to decide which of the plugins described in this tutorial to use for your WooCommerce hidden store. Read the 2 lists below and then skip to the method that best applies to you. Or to make it easier, take our quick quiz!
- Want to hide your whole WooCommerce store?
- Need your WooCommerce shop page and ALL your products, categories and tags to be completely hidden from search engines, sitemaps etc?
- Want all customers to have access to all the products within your WooCommerce hidden store?
- Want to hide some of your WooCommerce products, while also having a public online shop?
- Need to give different customers access to different products within your hidden store?
Method 1 - Hide Products with the WooCommerce Private Store plugin
The WooCommerce Private Store plugin is the easiest way to make WooCommerce private. It creates a 100% WooCommerce hidden store, locking down your entire shop behind a single password. Alternatively, you can automatically unlock your private store for logged in users or specific roles. No one will know your hidden store exists unless you want them to! So if you need to disable a store temporarily, this is a great option.
This video tutorial will tell you how to set up your WooCommerce hidden store. I've also provided written instructions below.
Still not sure if our WooCommerce Private Store plugin is for you? Have a look at this customer review or check out the Montana Medicinals case study below.
If you want a Private Store, Look no further!!
Case study #1 - Sprezzatura Imports
After registering, distributors can purchase products and gain access to the price list by logging in to the password protected area. Then, to make it even easier for distributors to login, the login page was added to the menu. As a result, the hidden WooCommerce store is just a matter of clicks away from the homepage.
Case study #2 - Montana Medicinals
Montana Medicinals needed to password protect their shop to comply with laws in the state of Montana. That's because Montana Medicinals operate a medical marijuana dispensary and only pre-authorized customers are allowed to access the shop. That's why they used our WooCommerce Private Store plugin.
To limit access to those over 18, they also used a sitewide WordPress age verification plugin.
Within a matter of minutes of installing the WooCommerce Private Store plugin, the developers had created a password protected private store. Customers registered with Montana Medicinals are given a password to access the store. Once a user has confirmed they're over 18, they can access the site. Anyone can read general information about getting prescriptions, but to view products and start shopping you need a password. Clicking on Shop or Products prompts the customer to enter their password. And without a password you can't access the private store.
Read on to find out how to hide WooCommerce stores or even temporarily disable online shops.
1. Install WooCommerce Private Store
- First, buy WooCommerce Private Store.
- Download the plugin files and copy your license key from the confirmation page or order confirmation email.
- In the WordPress admin, go to Plugins → Add New and upload the plugin files.
- Activate the plugin.
- Next go to WooCommerce → Settings → Private Store and paste your license key. Change the other settings as required.
- Create a store login page by adding the shortcode
[store_login]anywhere on your site.
And that's it! That's all you need to do to hide products in WooCommerce and make your store private.
The next few steps will let you further configure your hidden WooCommerce store. However you've already done the most important bits and your store is secure and hidden.
2. Customise the WooCommerce login page (optional)
If you like, you can customise the text that appears above the password entry form for your WooCommerce hidden store. You can also change the text on the 'Submit' button. You can do all this on WooCommerce → Settings → Private Store.
Make any changes and then check the WooCommerce login page that you selected in step 1.6 (above) to ensure it looks ok.
You can also add text and other content above and below the password entry form, directly onto the WooCommerce login page.
3. Link to the store login page (optional)
All WooCommerce hidden stores are different. You might want to include a link to your store login page on your public site. For example if you're creating a WooCommerce wholesale shop then you might want to add a 'Wholesale Login' page to the menu or header. Or you might want to keep your WooCommerce store hidden so that only people with the link can ever find it.
You can link to the store login page in the usual way for adding a link in WordPress.
4. Add additional store login forms (optional)
You can also add login forms anywhere else on your public site - for example on another page or sidebar widget. In this screenshot, I've added a login form to a text widget in the right hand column.
To do this, add the shortcode
[store_login] to any page, post or text widget. (Or if you're a developer, you can add it elsewhere such as in the header or a popup login form.) This will insert a login form and the text that you added to the settings page in step 2.
Customers can use this to access your WooCommerce hidden store while everyone else remains locked out.
5. Add WooCommerce content to the menu
If you haven't already done this, you can edit your navigation menu to include links to the main WooCommerce store page or to specific products, categories or tags.
Go to Appearance > Menus and select the relevant page/products/categories/tags. Add them by ticking the correct box and clicking 'Add to Menu'. (If you add them as Custom Links then the WooCommerce hidden store plugin won't hide them.)
If you use this method then the shop page/products/categories/tags in your menu will be invisible until you enter the password to unlock the hidden store.
You can see this in action on the password protect WooCommerce plugin demo. When you first view the site there's no menu dropdown under the 'Hidden Shop' link. Once you enter the password, hover over 'Hidden Shop' and you'll see that links to various WooCommerce content have magically appeared!
6. Check your WooCommerce store is hidden
Now comes the fun part. Visit your public website and try to find your WooCommerce hidden store:
- Try accessing any of your WooCommerce pages - e.g. your main Shop page, a product or specific category. You'll be taken to the store login page.
- Do a Google search for one of your hidden WooCommerce products.
- If you have a search box on your site, see if your hidden WooCommerce content appears in the results.
- Check your XML sitemap.
- Test the navigation menu.
- Check that no WooCommerce widgets (e.g. Products, Product Categories or Product Filters) are showing.
We've developed the WooCommerce hidden store plugin to be completely private and hidden. If you find any loopholes (e.g. you might be using a WordPress SEO plugin that we haven't tested), let us know.
Once you're happy that your WC store is 100% hidden, go to your login form and enter the password. Now you can test what customers will see after they unlock the private store.
7. Give the password to your customers
When you're completely happy with your WooCommerce hidden store, you can start using it. Give the password to your customers. And if you haven't added a 'Store Login' link to your public site, give them the URL too.
Or if you've ticked the 'Logged In Users' box in the settings, they just need to log into their account and the store will automatically unlock. There's also an option to choose which logged in users roles can access the store.
Method 2 - Hide Products with WooCommerce Password Protected Categories
WooCommerce Protected Categories is most commonly used to hide one or more product categories within a public online shop. However the plugin can equally be used to create a WooCommerce hidden store. This video and the written instructions below will show you how to create a private shop and hide WooCommerce products.
1. Create a main protected category to hide products
The first step is to create a main product category for your WooCommerce hidden store and protect it, either with a password or user login. By having one protected category, you can then structure your entire store within this category:
- In the WordPress admin for your website, go to Products → Categories. This is the standard WooCommerce category page, except that you will see a 'Visibility' section at the bottom left when you create or edit a category. This has been added by the WooCommerce Protected Categories plugin.
- Add a new category and call it anything you like. This will be the name of your WooCommerce hidden store.
- Click 'Protected' and either enter one or more passwords, or choose which users or roles will have access.
- Your new category will appear in the list of product categories on the right. You can see that it's protected in the 'Visibility' column.
Password protected categories is a good option for most WooCommerce hidden stores because you don't have to manage individual logins for each user. Everyone shares the password to your hidden shop, or you can give a different password to each person. Alternatively, choose the user or role protection options if you want each customer to have their own user account.
2. Add sub-categories to your WooCommerce hidden store
You can divide your WooCommerce hidden store into multiple categories if you like. (If not, skip ahead to step 3.)
Everything in your private WooCommerce store must be in a protected category or one of its sub-categories.
- Create each of your sub-categories using the 'Add new category' option on the left of Products → Categories.
- Select your main protected category as the 'Parent'.
- Leave the visibility as 'Public'. This is because the sub-category (and its products) will automatically be hidden using the same type of protection.
Once a customer enters the correct password or logs into their user account, it will unlock the entire WooCommerce store and all the hidden products. This saves them having to re-enter a password for each product as they navigate around the shop.
Note: If you want to create separate protected categories that are unrelated to each other, that's fine. You might want to do this if you want to create different private areas of your shop for different customers. For example, a photographer might create a separate hidden category to sell the photos for each client. You can then have a central login form which will direct each customer to their hidden category.
3. Hide products by adding them to a protected category
Next, it's time to put your products within the protected categories you just created:
- Go to the Products section of the WP admin.
- Hover the name of each product and click the 'Quick Edit' link that appears.
- Select one or more categories and click 'Save'.
- Repeat for all your other products.
When you add new hidden products to WooCommerce in future, you will also need to assign them to your store's hidden categories.
4. Link to your WooCommerce hidden store (optional)
Even if you are hiding your Woo shop, you might still want to link to it. For example, you might want to add a link called 'Client login' or 'Trade area' to your homepage, header or footer. You might want to link to it from the navigation menu and either make it publicly visible so that anyone can access the login page, or set it to only appear after customers have entered the password.
Of course if you want to hide the fact that your website even has an e-commerce store, you don't have to link to it at all. Instead, you can give your customers the link directly (e.g. via email).
There are 2 ways to let people find your hidden WooCommerce store. You can either link to a central WooCommerce customer login page, or link to each hidden product category.
Add a central WooCommerce customer login page
If you're using password protected categories, then the shortcode
[category_login] will add a WooCommerce customer login form. When customers visit this page, they can enter the password for any hidden WooCommerce product category. If the password is correct then they'll be redirected to the correct category page in your hidden WooCommerce store.
This option works well whether you have one or several protected categories in your WooCommerce hidden store. It's more flexible than linking directly to a protected category because you can add the WooCommerce login form to any page or widget. However I'll tell you how to do that next, just in case.
If you're using role or user protected categories, then you just need to link to a user login page instead. Use the free Peter's Login Redirect plugin to automatically redirect users to the correct hidden category after they log in. You can choose a different category for each user or role to be forwarded to - it's surprisingly flexible for a free plugin.
How to add links to a protected WooCommerce category
- Go back to Products → Categories. Hover over the name of your main hidden category. Right-click the 'View' link and copy the link. That will put the URL/address for your hidden category to your clipboard.
- Now go to wherever you want to add the link - e.g. your homepage, header or footer. Create a hyperlink in the usual way (either using HTML or the 'Insert/Edit Link' WordPress toolbar icon).
How to link to hidden product categories from the menu
- Go to Appearance > Menus.
- On the left, open up the 'Product Categories' section.
- Tick whichever protected categories you want to add to the menu OR the page where you have added the WooCommerce login form.
- Click 'Add to Menu'.
- The product categories will be added to the end of your menu on the right. Drag them to the correct position and click 'Save Menu'.
Now go back to your website and click 'Refresh'. If your private categories don't appear in the menu, that's because the plugin is set to only show them in the menu after you have unlocked the category. If you go to the main category for your WooCommerce hidden store and enter the password, the links will then appear in the menu.
To make the menu links visible to everyone, you can change this setting at WooCommerce → Settings → Products → Protected Categories.
5. Choose how your hidden WooCommerce product categories behave
The WooCommerce Protected Categories plugin lets you choose how the hidden part of your store appears publicly. You can change the plugin settings as follows:
- Go to WooCommerce → Settings → Products and click the 'Protected Categories' link at the top.
- Tick and untick the boxes to choose whether to hide your WooCommerce hidden products and categories from menus etc.
- This page also lets you change the text that appears above the 'Enter password' box and the wording of the button. For example you might add instructions on what to do if a customer loses the password.
6. Hide any global links to the WooCommerce cart
Depending on your WordPress theme, there might be publicly visible links to the cart which aren't hidden. If you want to hide a WooCommerce store, you probably don't want this to appear on your public website.
If you use a fully featured theme from ThemeForest or similar then the theme options might let you hide the cart icon. If your theme doesn't have this option then you can hide it using CSS. (We recommend Codeable for small coding tasks like this). Or even better, ask your WordPress developer to code the cart link to only appear when there are products in the cart. This will automatically hide it from your public-facing store because customers can only add products to the cart after unlocking the category!
7. Add the WooCommerce cart widget
If you've hidden the main links to your cart, you can use the WooCommerce cart widget to display the cart in the sidebar. This might be the right or left hand column on your WP site.
- Go to Appearance → Widgets.
- Find the sidebar area where you want the cart to display.
- Drag the 'WooCommerce Cart' widget from the left hand side to the correct sidebar area.
- Tick the 'Hide if cart is empty' box in the widget settings and click 'Save'.
By ticking 'Hide if cart is empty', the cart widget will only display when customers have products in their cart. Since your Woo store is hidden and people can only add products after they unlock the category, this stops it from appearing on your public website. Even if you have the same sidebar on the public and private areas of your website, the cart will only appear when there are products in the cart.
This means that it doesn't matter if you have hidden the shopping cart from the header, as it appears in the sidebar instead.
8. SEO - Block your WooCommerce hidden store from search engines
Finally, a note about SEO.
I won't cover this in-depth as it depends on your WordPress SEO plugin. As a general principle, you will want to mark all of the following as noindex:
- All the default Woo pages (Cart, Checkout, My Account and Shop).
- The Products custom post type.
- Product category pages.
- Product tag pages.
If you have an XML sitemap then you need to tweak the settings to exclude.
Use the documentation for your WordPress SEO plugin to find out exactly how to do this.
This will hide the hidden areas of your WooCommerce store from search engines while allowing search engines to index your public pages.
9. Hide WooCommerce products from the WordPress search
By default, the products in your hidden product categories will appear in the website search but if you click them then you will be prompted for the password. This also applies to other WooCommerce content such as your main shop page, categories and tags.
You can stop your hidden WooCommerce products from appearing in the WordPress search results at all. To do this, you need to set the "Catalog Visibility" option for each product to "Hidden". You can find this option in the 'Publish' section on the right hand side of the Edit Product screen:
This advice applies to the default search feature that is built into WordPress. If you're using a different search plugin, it's worth testing this to make sure it works for your plugin.
If you're worried about hidden WooCommerce products appearing in the search, you may be better off with Method 1 and our WooCommerce Private Store plugin. That plugin hides products from the search results automatically.
Further reading: How to Build a Private WooCommerce Members Only Shop
In this tutorial, we have used 2 different plugins to create a WooCommerce hidden store. We've added links to it - either to the menu or to anywhere else on your website. We've dynamically added links and widgets so they only appear once people have unlocked a category.
Both plugins let you hide products and protect a WooCommerce store within your WordPress website. WooCommerce may be most popular for public online shops, but it's just as good for hidden WooCommerce shops. Whether you want to hide WooCommerce wholesale areas, customer-specific products, temporarily hide stores, or create a WooCommerce age restricted area, you can do it with these plugins.
I hope the tutorial has been useful for you. Use the plugin documentation for WooCommerce Protected Categories or WooCommerce Private Shop to learn even more about your chosen hidden store plugin. Or if you like the plugin, become a Barn2 affiliate and earn 30% commission for recommending our plugins!
Are you using one of these methods to hide products in WooCommerce? I'd love to hear how it's working for you - please add a comment below.