WooCommerce – Hide Payment Method based on Product Vendor

In this post, we’ll show you how to hide payment methods based on product vendors in WooCommerce. If you have a multivendor platform, you can block a specific payment method for certain vendors. And the best part is that you don’t have to program anything. Just a few clicks, and you’ll be done.

We’ll do it using the WooCommerce Conditional Payment Gateways plugin. You can enable or disable any payment gateways based on information from cart, user details, product details, and dates.

Here are just some examples:

  • Require bank transfers when the order is higher than $2000 to save on fees
  • Require bank transfers when your distributors or partners make wholesale purchases
  • Require cash payment when the product will be home delivered
  • Require cheque payment for expensive products to prevent fraud
  • Allow credit cards for users with 3 or more successful purchases reducing credit card fraud

In this example, we’re using vendors created with Dokan. We’ll hide a payment method based on a Dokan product vendor.

Once you install and activate the plugin, you need to follow these simple steps:

1- Create a new condition for you payment gateways

First, you need to create a new condition for you payment gateways with the WooCommerce Conditional Payment Gateways plugin.

  1. Go to WooCommerce > Conditional Payment Methods.
  2. Tick the Enable conditions checkbox.
  3. Click Add condition to create a new condition.

woocommerce hide payment methods product vendors

2- Hide payment methods based on product vendor

Once you’re in the create condition form, you need to select the following values to hide payment methods based on product vendor.

  • What happens when the conditions are met: Disable the payment method(s)
  • Select the payment methods: Select the payment methods you’ll disable. PayPal, for example.
    • If your gateway doesn’t appear, tick the My gateway doesn’t appear in the list checkbox and add the gateway.
  • Condition 1: Vendor = Nancy West, for example.
    • If you want to add another vendor, click Add ‘Or’ group and select the new condition.
  • Publish the condition.

woocommerce hide payment methods product vendors

That’s really simple!

As you see, it’s really simple to hide payment gateways based on product vendor. You don’t need to program anything. With a few clicks, you can hide any payment method for specific product vendors.