For the complete documentation index, see llms.txt. This page is also available as Markdown.

B2B customer

Restrict a lock to customers who belong to a Shopify B2B company account.

The B2B customer rule checks Shopify's own native company-account status for the visitor — it's a genuine platform check against Shopify's B2B customer flag, not something the app tracks on its own. If a customer is associated with a company account in your store's B2B setup, this rule recognizes them as a B2B customer automatically.

How it works

The rule reads whether the currently logged-in customer is linked to a Shopify B2B company account. There's nothing to configure beyond adding the rule and choosing If/Unless — no tag to type, no list to maintain. That also means the rule is only as accurate as your store's own B2B setup in Shopify: if a wholesale buyer hasn't been added to a company account in Shopify admin, this rule won't recognize them as B2B, no matter how you configure it here.

Adding the rule

  1. Open the lock you want to protect and click the Unlock rules tab.

  2. Add an access rule and choose B2B customer from the Condition type dropdown.

    Access rule picker with B2B customer selected as the condition type
    Adding the B2B customer rule — no extra setup needed beyond If/Unless.
  3. Choose whether the rule should match If (the customer belongs to a B2B company account) or Unless (the customer does not).

  4. Optionally set a per-rule Redirect URL.

  5. Save the lock.

Common use: hide retail pricing from non-B2B visitors

A typical setup pairs this rule with Hide price and Add to cart:

  1. On the Lock setup tab, set the content to lock to the products or collection with B2B-only pricing.

The Lock setup tab with Specific products chosen as the content type and two products listed under Restricted products.
Pick the products whose pricing should stay B2B-only.
  1. Click the Unlock rules tab to continue.

  2. Add the B2B customer rule, matching If. There's nothing more to fill in — the app notes "No extra setup needed. This condition uses Shopify B2B customer status."

The B2B customer condition with Rule logic set to If and a note that the condition uses Shopify B2B customer status.
The condition heading confirms what you built: If the customer is a B2B customer.
  1. In the same tab's right-hand sidebar, under Blocked visitor behavior, leave Hide products from storefront off and pick a hide option from the dropdown instead — so non-B2B visitors see the page without the retail price or buy button, rather than a hard block.

The Blocked visitor behavior panel with Hide products from storefront unchecked and Hide product price and atc selected in the dropdown.
Hide product price and atc keeps the page visible while the pricing stays private.
  1. Save.

If you're segmenting purely by a customer tag rather than genuine Shopify B2B company status, the Customer tags rule and the built-in Quick Setup Wholesale-only products template on the Locks page are a faster shortcut. Reach for this B2B customer rule specifically when you want the check tied to real B2B company accounts in Shopify, not a tag you maintain yourself.

Result on the storefront

With the example above, customers linked to a Shopify B2B company account see the normal price and buy box. Guests and signed-in retail customers can still browse the product page, but the price and buy buttons are replaced with the configured lock message.

A live storefront product page seen by a non-B2B visitor: product image, title, and vendor are visible, with a Login to see price link where the price would be and no Add to cart button.
The result of the example: non-B2B visitors can browse the product, but the price and buy buttons are replaced.

The default replacement text may say "Login to see price". Because a signed-in retail customer can still fail the B2B condition, consider changing it to something more specific, such as "Company account required". See Hide price and Add to cart.

Last updated

Was this helpful?