WooCommerce login for your customers: The ultimate guide

August 12, 2021

WooCommerce Login Plugins

This guide contains everything you need to know about WooCommerce login for your customers. We'll look at the different ways you can let customers log into a WooCommerce online store, and why.

I'll tell you how to set up WooCommerce login straight out of the box, with or without compulsory registration and social login. I'll also share some handy login plugins to create a hidden or private WooCommerce store that only logged in customers can access.

What are the different types of WooCommerce login?

By 'WooCommerce login', I'm talking about the process where customers log into your online store. It's quite a vague term and there are several ways to set it up. Which one you choose depends on how you want your store to work.

  1. Public WooCommerce store with guest checkout - This is the most common WooCommerce setup. Anyone can browse your products and there is no hidden WooCommerce content. Customers can buy products as a guest without having to login, or they can optionally create an account during checkout.
  2. Public WooCommerce store with mandatory user accounts - Lots of WooCommerce stores can be browsed by anyone, but customers must register or login to their account in order to purchase.
  3. Customer portal with protected product categories - Instead of (or as well as) individual customer accounts, you can password protect parts of a WooCommerce store or restrict them to specific users or user roles. Anyone can buy from the public areas of your shop, while only customers with the right credentials can access your protected categories. Once a customer logs into your protected categories, they can view and buy the hidden products inside.
  4. 100% private WooCommerce store - Some websites want to hide a whole WooCommerce store from public view so that customers must login or enter a password to access it.
  5. WooCommerce auto-login links - Let customers login more easily by clicking on a personal login URL. No more usernames or passwords!

With nearly 2 million websites using WooCommerce according to the latest WooCommerce stats, there are plenty of people looking for all these login options.

Which type of customer login is best for my WooCommerce store?

I've created a quick quiz to help you with this. Answer the simple questions about your requirements, and the quiz will recommend the best WooCommerce login plugin for your website.

Option 1 - Public WooCommerce store with guest checkout

Most WooCommerce stores let anyone view and buy their products, whether or not they're logged in.

How to enable guest checkout in WooCommerce

  1. Log into the WordPress dashboard and navigate to WooCommerce → Settings → Checkout.
  2. You'll see a box with the label 'Enable guest checkout'.
  3. Tick this box and customers will be able to purchase without logging in or creating a user account.
WooCommerce guest checkout

How to prevent user account creation in WooCommerce

If you like, you can prevent customers from creating user accounts at all. To do this, go to WooCommerce > Settings > Accounts. Untick the boxes to enable registration on the Checkout and My Account pages. This will prevent customers from registering for your site at all, so you don't need to provide a login page.

WooCommerce prevent user account creation

Check out this free Helpie WooCommerce FAQ plugin which helps to create an FAQ section on your WooCommerce product page to easily answers customers question about the products.

Option 2 - Public WooCommerce store with mandatory user accounts

How to add a Register/Login page to WooCommerce

WooCommerce login register
When you first install WooCommerce and run the Setup Wizard, there's an option to automatically create all the essential pages for your store. Do this, and you'll see a 'My Account' page in your list of pages (along with other new pages for shop, cart and checkout).

The shortcode [woocommerce_my_account] will appear on the page. You can use this page as your register/login page, for example by linking to it from your header or sidebar.

The WooCommerce login/register form works as follows:

  • Guest users will see the WooCommerce login form, possibly with a registration form. To include the registration form on the login page, go to WooCommerce → Settings → Accounts and tick 'Enable registration on the "My Account" page'.
  • Logged in users will see their Account page, with their order history, profile and other information.

You can add the [woocommerce_my_account] anywhere else on your website to create extra login forms. There are other plugins available to do this such as Sidebar Login and Woocommerce Login / Signup Lite. These let you create more complex WooCommerce login forms. However you only need an extra plugin if the built-in WooCommerce login shortcode isn't suitable for you.

Tip: If you want to control where users are redirected after they login, try Peter's Login Redirect. It's easy to set up and we've used it on lots of our clients' websites.

How to force WooCommerce customers to login or register before they buy

  1. In the WordPress dashboard, go to WooCommerce → Settings → Checkout.
  2. Untick the 'Enable guest checkout' box. This will force users to create an account when they buy from your WooCommerce store.

You can further configure how user accounts are created in WooCommerce → Settings → Accounts. This WooCommerce page has several settings such as whether to include a registration form on the checkout page and whether to automatically generate customer login usernames and passwords.

There's also a box to display a login reminder on the checkout so that existing customers can login. This is really useful if guest checkout is disabled, as you need to make it easy for customers to login.

Note: If a customer completes checkout without logging in then an account will be created for them behind the scenes. They will receive the login details by email so that they can login next time they purchase from you.

WooCommerce social login

WooCommerce social login
As well as the standard WooCommerce login facility, you can let customers login with their social media accounts. With WooCommerce social login, you create a public store as usual so that anyone can browse your products. As part of the checkout, they can log into your website using their social media accounts.

You might offer social login in addition to - or instead of - the option to register directly on your WooCommerce website.

Research suggests that over 77% of customers prefer to log into WooCommerce or other websites using social media. This is hardly surprising given that it saves them the hassle of creating a new account for your website and remembering their logins. (And of course, WordPress insists on secure passwords these days so they can't just login with an easy-to-remember password!)

Back in 2014, I wrote about a 'deadly embrace' caused by WordPress social login plugins. At the time, the available plugins conflicted with built-in WordPress user accounts. Things have improved since then but if you're considering social login then I recommend you use the official WooCommerce extension. This offers the best chance of creating a user-friendly WooCommerce social login for your website.

How to add social login to a WooCommerce store

To add social login to your WooCommerce website, I recommend the official WooCommerce Social Login plugin. Once you've purchased the plugin, follow the instructions in the knowledge base to enter your license key and set it up.

Given the issues I previously identified with social login, I recommend thorough testing before it goes live. Make sure your WooCommerce login process works seamlessly. In particular, test the following aspects of the login process:

  • First time WooCommerce logins using each social network.
  • Repeat logins using the same social network.
  • Repeat logins using a different social network. (i.e. what happens if a customer forgets which social network they logged in with previously?)
  • Register using social login and then try logging in directly on the website using the Lost Password link.

Basically, try to break it and send a support request to WooCommerce if you discover any problems. Social login is a great idea but needs thorough testing to get right, as customers may forget how they previously logged into your WooCommerce store.

Get WooCommerce Social Login

Option 3 - Login portal with WooCommerce protected categories

WooCommerce Password Protected CategoriesOptions 1 and 2 are about letting customers login to a public WooCommerce store. They might have to login to purchase, but anyone can browse the store and see the products. You can also create a WooCommerce login system where customers have to login or enter a password in order to see your products or other store content.

The WooCommerce Protected Categories plugin creates a login portal where different customers can see different products. It locks down one or more of your product categories so that no one else can see them. Customers must log into WooCommerce with the correct credentials to see the products inside their portal.

You can create separate categories for different groups of customers, and you can even create customer-specific products. Each customer logs in and views the restricted products that they have access to.

WooCommerce Protected Categories
Start creating hidden login-only product categories today.

Who needs protected product categories?

You can use WooCommerce Protected Categories in several ways:

  • Show products from protected categories in the public areas of your store. When someone clicks a protected product, they must enter the password or login to view the single product product page or purchase. This lets you display all products in the public store, while only pre-approved customers can buy protected ones.
  • Hide protected categories and products from the public store. Alternatively, you can hide protected WooCommerce categories and their products from public areas of your store. Authorized users can login and be directed to the correct hidden category. This is perfect WooCommerce wholesale stores or customer-specific products where you sell different products to each customer.
  • Hide your entire WooCommerce store. Finally, you can put ALL your products within one or more protected categories. This way, customers have to login before they can view your products or buy. (Tip: While it's possible to hide your whole store with this plugin, you might prefer Option 5, below. Both plugins let you create a WooCommerce hidden store)

How to create protected categories in WooCommerce

You can read full setup instructions in the plugin knowledge base. Here's a quick guide to get you started:

  1. First get WooCommerce Protected Categories.
  2. Install and activate the plugin.
  3. Go to WooCommerce → Settings → Products → Protected Categories and enter your license key.
  4. Change any settings such as customising the text on the password login page, and whether to hide protected categories from the public areas of your store.
  5. Now, go to the product category that you want to hide behind the login page. You'll find this in Products → Categories. The plugin has added a new 'Visibility' section with options to password protect the category or make it private. Choose 'Protected' and either password protect the category, or restrict it to specific users or roles.
  6. Repeat step 5 for all the categories you want to protect.

Finally, test your WooCommerce protected categories from different customer login scenarios. For example, try it when you're logged in and out of the website. Also try it before and after you login to a category.

Option 4 - Create a login-only store

WooCommerce store login

WooCommerce Private Store forces customers to login to your WooCommerce store before they can see your shop page, products, categories or any other store content. It's a simple but effective plugin to hide WooCommerce from public view, without affecting the public parts of your site.

By logging into their user account or entering a simple password on the WooCommerce private store login page, customers can unlock the store and access the products and other content inside. Your public users won't even know you have a WooCommerce store, unless you decide to link to the login page. (In which case, they will be able to see the WooCommerce login page but none of the content behind it.)

WooCommerce Private Store
Create a login-only WooCommerce store in under 2 minutes.

How to hide your whole WooCommerce store behind password protection or user login form

The plugin knowledge base contains full setup instructions for WooCommerce Private Store. I've also provided details below. Setting it up literally just takes a few minutes:

  1. Buy the plugin from https://barn2.com/woocommerce-private-store.
  2. Go to WooCommerce > Settings > Products > Private Store.
  3. Enter your license key and change any settings such as customizing the WooCommerce login form text. Either choose a password to password protect WooCommerce, or tick the 'Logged In Users' option to automatically unlock it for logged in users or specific roles.

Once you've saved the settings page, your whole store will be protected. Customers will have to login or enter the password before they can see ANY WooCommerce content such as the main shop page, products, categories etc. Your WooCommerce content will also be blocked from search engines, so it's a simple yet secure way to make WooCommerce private.

WooCommerce Protected Categories or Private Store?

I realise that the plugins mentioned in options 4 and 5 are quite similar. You can use them in similar ways but they can also be used very differently in terms of WooCommerce login options. Check out my article and quiz on which WooCommerce protection plugin to use.

Option 5 - WooCommerce auto-login by URL

Finally, you might want an easier way for your WooCommerce store's customers to login.

WordPress and WooCommerce auto-login plugins provide a dynamic link that automatically logs customers into their accounts. This saves customers having to remember or store usernames and passwords. All they need is their personal auto-login URL.

You can use this option with options 1, 2, 4 and 5 listed above.

For full instructions, check out our separate guide on how to set up WooCommerce auto-login URL's.

What type of WooCommerce login do you use?

As you can see, there are many types of WooCommerce login designed for different types of store. I hope this guide has helped you to choose the right login method for your website, and to set it up properly.

How do you allow customers to login to your WooCommerce site? Are there are good plugins I've missed? What pitfalls did you come across and what would you advise other WooCommerce users? Please add your comments below.


  1. Dami
    September 30, 2021 Reply

    Hello, I'm having an issue with my customer account creation profile on my WooCommerce website. It leads users to the wordpress wp-login page instead. Please help. Thank you.

    • Salo
      October 13, 2021 Reply

      I am having the exact same probem, that looks terrible. How can we avoid this?

      • Jae Narra
        October 14, 2021 Reply

        Hi Salo, thanks for your comment. Please see my colleague's (Edge) response (dated 2nd Oct) regarding this issue.

        We hope this helps. Thanks!

    • Edge
      October 2, 2021 Reply

      Hi, Dami. I'm sorry to hear this and thanks for asking. The issue you're experiencing could be due to the options that you've set under WooCommerce > Settings > Accounts & Privacy in the WordPress Dashboard of your site. Should you continue to have difficulty with this, I suggest that you contact official WooCommerce Support for the best advice to resolve it. I hope this helps and points you in the right direction should you need further assistance with WooCommerce on your site. Cheers.

  2. Ahmad Hijazi
    September 15, 2021 Reply

    Hi, howdy? I wondering if there is a solution to disable the login or register option when an account is already logged in? Thanks in advance

    • Nikki
      September 16, 2021 Reply

      Hi, Ahmad. You can do/implement this by adding it as customization or a bespoke feature. You may also reach out to WooCommerce Support regarding plugins that can control the visibility of Menu Items e.g. If Menu. You may also refer to the official WooCommerce Docs. Hope this is helpful!

Please share your thoughts...

Your email address will not be published.