Shopify B2B Shipping: The Secret to Hiding Rates & Offering $0 for Customer Accounts

Hey everyone! As a Shopify expert who spends a lot of time digging through the community forums, I often see incredibly insightful discussions that help unlock complex challenges for store owners. Recently, a thread popped up that really caught my eye, focusing on a super common B2B shipping scenario: allowing customers to use their own UPS account for shipping, effectively making their shipping cost $0, and crucially, hiding all other shipping methods at checkout. This isn't just a 'nice to have' for many businesses; it's a core requirement.

Our community member, JoeBTI, kicked off the discussion, describing exactly this challenge. He was testing Shopify's Checkout UI Extensions and Functions on a development store, trying to add a “Ship on My UPS Account” option directly within the shipping block of the checkout. The goal was twofold: hide all other shipping methods if this option was selected, and then update the shipping cost to $0.00. He even shared a helpful screenshot:

The Initial Hurdles and the Clever Solution

At first, another community member, Steve_TopNewYork, suggested that while Checkout UI Extensions are great for collecting information, they might not be able to dynamically hide shipping methods or set rates to $0. His workaround idea was to capture the UPS account details during checkout and then adjust the shipping charge or issue a refund after the order was placed. This is a totally valid — and common — approach, but as many of us know, post-order adjustments can add extra steps to your fulfillment workflow and aren't always ideal for a seamless customer experience.

However, the real “aha!” moment came from HamidEjaz, another expert in the thread. He clarified that JoeBTI's goal is absolutely doable, but it requires a powerful combination of two distinct Shopify extensibility tools:

  1. A Delivery Customization Function: This is the workhorse that actually does the hiding, renaming, or reordering of delivery options. It reads a “cart attribute” (more on that in a sec) and, based on that attribute, tells Shopify to hide every method except your special $0 UPS rate.
  2. A Checkout UI Extension: This is the customer-facing piece. It collects the customer’s UPS account details and, when they select “Bill to my UPS account,” it uses the applyAttributeChange API to set that crucial cart attribute. The Delivery Customization Function then “keys off” this attribute.

Here’s the critical detail Hamid pointed out: Delivery Customization Functions can hide and rename, but they cannot change a rate’s price. This means your $0 shipping option needs to be a real shipping rate you’ve already configured. You’d create a flat rate, call it something like “Ship on my UPS account,” and set its price to $0.00.

Putting It All Together: Step-by-Step Flow

So, instead of a post-order refund, you get a real-time, dynamic checkout experience. Here’s how the entire flow works:

  1. Configure Your $0 Shipping Rate: First things first, go into your Shopify shipping settings and create a new flat shipping rate. Name it clearly, something like “Ship on my UPS account,” and set its price to $0.00. This is the rate you want customers to see.
  2. Develop Your Checkout UI Extension: This extension will live in your checkout’s shipping section. It will display a checkbox or radio button for “Bill shipping to my UPS Account” and perhaps an input field for their UPS account number. When the customer selects this option, your UI Extension will use the applyAttributeChange API to set a specific cart attribute (e.g., shipping_on_customer_account: true).
  3. Build Your Delivery Customization Function: This Function will run live during the checkout process. It will check for the presence of the cart attribute you set in step 2. If it finds shipping_on_customer_account: true, it will then “hide” all other shipping methods, leaving only your predefined “Ship on my UPS account” $0 rate visible to the customer.

Hamid also confirmed that this approach works seamlessly whether you’re using CarrierService rates (from a third-party app) or plain Shopify Shipping rates. The Function acts on whatever delivery options are returned, so it handles both equally well.

Why This Approach Wins

This combined approach offers a much cleaner and more professional experience for your B2B customers. They get immediate confirmation of their $0 shipping at checkout, without the need for manual refunds or adjustments after the fact. It leverages the powerful, modern extensibility features of Shopify to solve a very real-world business problem.

It’s a fantastic example of how Shopify’s platform is evolving, giving merchants more control and flexibility than ever before. If you’re looking to implement advanced shipping logic or other custom features for your store, diving into building on Shopify with Functions and UI Extensions is definitely the way to go. It truly transforms the checkout experience, making it tailored to your specific business needs.

Share:

Start with the tools

Explore migration tools

See options, compare methods, and pick the path that fits your store.

Explore migration tools