WooCommerce: How to Assign Free Shipping to a Single Product?

Believe it or not, the answer to this very frequent question is inside the WooCommerce settings… so don’t worry too much about coding if you’re not a developer!

From the WooCommerce shipping rates, you can select “Free Shipping” as a method but that would apply to ALL products – so how do you override the shipping settings and allow a single product to have free shipping?

1. Create a Shipping Class

From the WordPress dashboard, go to WooCommerce > Settings > Shipping > Shipping Classes > Add Shipping Class. Call it “Free Shipping” or whatever you like.

Defining a new shipping class in the WooCommerce settings

2. Assign the new Shipping Class to your Product

Edit the product that requires free shipping by going to Product Data > Shipping > Shipping Class and assigning the “Free Shipping” shipping class to it. Update the product (if you go back to the admin page WooCommerce > Settings > Shipping > Shipping Classes, you should now see a “1” under “Product Count”).

Assigning a shipping class to a WooCommerce product

3. Set up a Flat Rate based on Shipping Class

Go to WooCommerce > Settings > Shipping > Shipping Zones. In each zone you should have at least 1 Flat Rate. Edit each Flat Rate, and make sure:

  • Cost is $0
  • “Free Shipping” class cost is $0
  • “No shipping class” cost is whatever it would be for other products
  • “Charge per class” is enabled
How to set up a Flat Rate to enable per-product shipping

That’s it.

Now if the product is in the cart and you’ve set up things properly, shipping will be free for it alone  🙂

Rodolfo Melogli

Author, WooCommerce expert and WordCamp speaker, Rodolfo has worked as a WooCommerce freelancer since 2011. His goal is to help entrepreneurs and developers overcome their WooCommerce nightmares. Rodolfo loves travelling, chasing tennis & soccer balls and, of course, wood fired oven pizza.

28 thoughts on “WooCommerce: How to Assign Free Shipping to a Single Product?

  1. Hi, I have successfully do what you said in the post, and it works well 🙂
    My issue is that when the conditions are met (there is a product on the cart with the “Free Shipping Class”) on the checkout page, I see:
    Shipping: Flat Rate
    Is there a way to show other than Flat Rate, this is confusing for customers.. (shows flat rate without any cost or number)
    Thank you.

    1. Cool! Maybe you can rename the shipping rate label from the settings?

  2. Thank you for this great solution!

    1. Cool!

  3. Hi, if the item costs $100 and to ship it costs our company $15 – but the customer sees the price as “$115 and Free shipping”.
    How is the shipping calculated/split in the backend given the application of “free shipping”? for tax and costing purposes.

    1. Hey Adam – if you use Free shipping, you will see $0 shipping

  4. I am equally confused the same way as others are when our store already has other shipping methods set up.

    Typically, we run only FedEx shipping method for all products, all zones, all classes. In the past, the only time we offer free shipping is with a discount code. But this time, we wanted to run a sale/promotion to include free shipping for only one product without the need for a code so this solution looked perfect.

    But when this approach is utilized and other products/classes exist in the cart, the Flat Rate shipping method is included with the FedEx shipping method. Then, the shipping options resort to the flat rate table lookup based on each class. But we do not have flat rate options for the other classes (we have FedEx shipping options) In other words, this solution only works if you are able to operate under a flat rate approach for all products/classes, not just the one you want to offer free shipping for. Is that correct?

    1. Yes Blake, this works out of the box if there is only one product in the Cart. For more complex scenarios, there’s always custom PHP that can give you solutions, but I’m afraid this is custom work. If you’d like to get a quote, feel free to contact me here. Thanks a lot for your understanding!

  5. What about if I’m looking to make product A’s shipping free but charge shipping for product B using USPS’s API. So for example if both products A and B are in the cart, the only shipping that would be calculated is for product B. Product A’s shipping cost is simply not calculated by USPS’s API. Is this possible? And if so how? I keep finding that when I label product A as free shipping, and have both product A and B in the cart that it simply gives me a free shipping option for the entire order or a calculated shipping cost from USPS’s API that factors in both products.

    Let me know if this is clear or if I can clarify any details.

    Thanks!

    1. Hi Kyle, please ask USPS plugin support

  6. hi,
    I have free shipping products and paid shipping products in my website. paid shipping products are configured as per weight based shipping as am selling some heavy items. So i need the following scenarios to be configured.
    1. Free shipping method should be applied when only free shipping products available in cart,
    2. Weight based shipping method should be applied when a customer add any other products along with free shipping products.

    Hope my idea is clear to you. Any help would be apreicated

    1. Hello Vahid, thanks so much for your comment! Yes, this is definitely possible, but I’m afraid it’s custom work. If you’d like to get a quote, feel free to contact me here. Thanks a lot for your understanding!

  7. Is there an option to offer free shipping for the entire order IF the order contains ANY product with the free shipping class? As soon as my customer adds a product from another class shipping gets added to their order. If our customer orders from class x then products in class y should also be shipped free of charge despite being under the usual threshold for free delivery.

    1. Hiya Mariella, thanks so much for your comment! Yes, this is definitely possible, but I’m afraid it’s custom work. If you’d like to get a quote, feel free to contact me here. Thanks a lot for your understanding!

  8. Hello,
    I don’t get the point. If I set up the flat rate to 0€ the other products also won’t have shipping costs..
    Am I missing something?

    Thank you

    1. The other products have no shipping class, so they will be priced differently as long as you follow this tutorial 🙂

  9. Hi, one question: what if “No shipping class” cost can not be one price but depends on shipping method?

    1. Hi Marek, thanks so much for your comment! Yes, this is possible – unfortunately this is custom work and I cannot provide a complementary solution here via the blog comments. Thanks a lot for your understanding! ~R

  10. Hi, I tried this method and I still can’t figure out what I am doing wrong. I noticed that it now shows up the customer can choose this free shipping option along with the other shipping cost options no matter what products are in the cart. not just the dedicated one

  11. Hi. The shipping class is still showing as an option even when I do not have the item in the cart. I can’t figure out what I am doing wrong.

    1. Hey Taylor, thanks for your comment! Did you follow the instructions @ point #3?

  12. Does this work with Variable products? For the life of me i can not get it to take?

    1. Of course Ryan, just apply the free shipping class to each single variation 🙂

  13. After hours of googling and trying everything under the sun to get this to work, including a free plugin that I found out later only gave free shipping to ALL the products in the cart ;p yours worked on the first go round! Not only did it work for free shipping on my charity item and not the other items, but it didn’t automatically add shipping to every item in the cart (instead of just the cart of items). Thank you! book marked in case I ever have to do this again.

    1. Awesome 🙂

  14. Hi

    I am using the Table Rates Shipping plugin. Can I use this to designate one product for free shipping?
    I am trying to complete the setup of my store as I open in a few days and am panicking a bit.

    WooCommerce support has been great but this is a detail I’m having trouble with.

    I will really appreciate your help here.

    1. Hello Marilyh, if you use that plugin you won’t need this snippet, you can achieve that from its settings 🙂

Questions? Feedback? Support? Leave your Comment Now!
_____

If you are writing code, please wrap it between: [php]code_here[/php]. Failure to complying with this (as well as going off topic) will result in comment deletion. You should expect a reply in about a week - this is a popular blog but I need to get paid work done first. Please consider joining #BloomerArmada to ask me 1-to-1 WooCommerce questions. Thank you :)

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.