How to separate the customer registration form from the seller (vendor) registration form in Dokan Multivendor?How to separate the customer registration form from the seller (vendor) registration form in Dokan Multivendor?

Hello guys how are you? Welcome back to my blog therichpost.com. Guys today in this post, I will tell show you How to separate the customer registration form from the seller (vendor) registration form in Dokan Multivendor?

Guys if you are new in WordPress or in WooCommerce then please check the below links for some good tutorials:

  1. Dokan
  2. Woocommerce
  3. WordPress

Guys to separate the customer registration form from the seller (vendor) registration form in Dokan Multivendor, you’ll need to implement a custom registration flow. Dokan by default uses a combined registration form with a “I am a seller” checkbox, but you can split this into two distinct forms with different URLs or tabs.


✅ Goal

  • One form for customers only
  • One form for vendors only
  • Each with its own styling and role assignment

🔧 Method 1: Use URL Parameter to Separate Forms

You can modify the Dokan registration form based on a query parameter (e.g., ?role=vendor or ?role=customer).

1. Add this to your theme’s functions.php:

add_filter( 'dokan_show_seller_registration', 'conditionally_show_seller_checkbox' );

function conditionally_show_seller_checkbox( $show ) {
    if ( isset( $_GET['role'] ) && $_GET['role'] === 'vendor' ) {
        return true; // show seller option
    }

    return false; // hide seller option for customer
}

2. Create Links to Each Form:

<!-- Link to customer registration -->
<a href="/my-account?role=customer">Register as Customer</a>

<!-- Link to vendor registration -->
<a href="/my-account?role=vendor">Register as Vendor</a>

Dokan will now hide or show the vendor checkbox based on the URL.


🛠️ Method 2: Create Two Separate Pages with Shortcodes

Step 1: Create Two Pages

  • Customer Registration: Use this shortcode
  [woocommerce_my_account]
  • Vendor Registration: Add custom logic to force vendor selection:
  add_action( 'woocommerce_register_post', 'auto_select_vendor_role', 10, 3 );
  function auto_select_vendor_role( $username, $email, $validation_errors ) {
      if ( isset( $_GET['vendor_register'] ) ) {
          $_POST['role'] = 'seller';
      }
  }

Step 2: Use Link

<a href="/register-vendor?vendor_register=1">Register as Vendor</a>

🧼 Optional: Customize the Templates

If needed, copy Dokan’s registration form template into your theme:

wp-content/themes/your-theme/dokan/global/seller-registration-form.php

Then edit it to create distinct forms or load different fields.


🚀 Result

  • Visitors can register only as customers or only as vendors depending on the link they use.
  • No need to rely on the confusing checkbox.
  • You maintain a clean and focused registration UX.

Let me know if you want a redirect after successful registration or need to customize the fields per role then feel free to comment below.

Ajay

Thanks

By therichpost

Hello to all. Welcome to therichpost.com. Myself Ajay Malhotra and I am freelance full stack developer. I love coding. I know WordPress, Core php, Angularjs, Angular 19, MedusaJs, Next.js, Bootstrap 5, Nodejs, Laravel, Codeigniter, Shopify, Squarespace, jQuery, Google Map Api, Vuejs, Reactjs, Big commerce etc.