Trending Bestseller Perfect rating Documented

Custom Shipping Methods for WooCommerce

(2 customer reviews)

From: $29.99 / year

Add custom shipping methods to WooCommerce.

$29.99 Single site1 year of updates and support30-day money-back guaranteeBuy
$79.99 Unlimited sites1 year of updates and support30-day money-back guaranteeBuy
$149.99Unlimited sitesLifetime updates and support30-day money-back guaranteeBuy


With Custom Shipping Methods for WooCommerce Pro plugin you can add custom shipping methods to WooCommerce.

Custom Shipping Methods for WooCommerce - Custom Shipping General Settings

In addition to standard WooCommerce cost calculation shortcodes ([qty], [cost], [fee]) you can also use [weight] and [volume] shortcodes.

The plugin also includes:

  • [costs_table] shortcode for the table rate shipping,
  • [distance] shortcode for distance based cost calculation,
  • options to set free shipping minimum order amount,
  • options to set min and max cost limits,
  • options to set custom shipping methods frontend icons and descriptions,
  • min/max cost/weight/volume/quantity method availability options.

Costs Table

[costs_table] shortcode has two attributes: prop and table.

prop attribute can be: volume, weight, qty, cost or distance.

table attribute sets costs based on prop attribute’s value, in min_prop-cost format.

Costs Table by Items Volume

Items volume is calculated by multiplying each item’s width, height and length.

[costs_table prop="volume" table="0-10|50-50|100-125.5"]

This example will set costs according to this table:

Volume Shipping Cost
from 0 and below 50 10
from 50 and below 100 50
from 100 125.5

Costs Table by Items Weight

[costs_table prop="weight" table="0-10|50-50|100-125.5"]

This example will set costs according to this table:

Weight Shipping Cost
from 0 and below 50 10
from 50 and below 100 50
from 100 125.5

Costs Table by Items Quantity

[costs_table prop="qty" table="0-20|10-10|20-0"]

This example will set costs according to this table:

Quantity Shipping Cost
from 0 and below 10 20
from 10 and below 20 10
from 20 free

Costs Table by Order Amount

[costs_table prop="cost" table="0-20|10-10|20-0"]

This example will set costs according to this table:

Order Amount (i.e. Order Cost) Shipping Cost
from 0 and below 10 20
from 10 and below 20 10
from 20 free

Costs Table by Distance

Distance is calculated same as in [distance] shortcode. Also same attributes (key, default_distance, units, src, debug) are applied.

[costs_table prop="distance" table="0-10|50-50|100-125.5" key="BIzbSyBNBNR9yi3vTgC33oXSpwQftScNSmO-fjc" default_distance="100" units="km"]

* Please note that key from example is not a valid key – you need to get your own key here.

This example will set costs according to this table:

Distance Shipping Cost
from 0 and below 50 km 10
from 50 and below 100 km 50
from 100 km 125.5

Distance based Cost Calculation

[distance] shortcode has five possible attributes:

  • key – this is a required attribute. Plugin uses Google Distance Matrix API to calculate the distance, so you need to get your API key here. Please note that you need to check “Routes” when getting your key from Google.
  • default_distance – this is a default distance for shipping (in case if customer didn’t enter his address yet or distance can’t be calculated). Default: 0.
  • units – units in which distance is calculated. Possible values: m for meters (default), km for kilometers and mi for miles.
  • src – source point (origin). By default it’s automatically retrieved from your shop’s settings from “WooCommerce > Settings > General > Store Address”. If you wish to set it manually – correct format is: address, city postcode, country.
  • debug – if set to yes, will output debug information in “WooCommerce > Status > Logs”. Default: no.

[distance] Example

1.5*[distance key="BIzbSyBNBNR9yi3vTgC33oXSpwQftScNSmO-fjc" default_distance="15" debug="yes" units="km"]

* Please note that key from example is not a valid key – you need to get your own key here.


If you need to round some values, you can use [round], shortcode, e.g.:


[round] shortcode attributes:

  • type – rounding type. Can be up, down and normal. Default is normal.
  • precision – rounding precision. Used for normal rounding type only. Sets the number of decimal digits to round to. Default is 2. This is the same parameter as in PHP round() function:

    If the precision is positive, the rounding will occur after the decimal point. If the precision is negative, the rounding will occur before the decimal point. If the absolute value of the precision is greater than or equal to the number of digits, the result of the rounding is equal to 0

Availability Options

For each custom shipping method you can optionally set min/max cost/weight/volume/quantity method availability options.

Custom Shipping Methods for WooCommerce - Availability Settings

Shipping Class Costs Options

As in standard WooCommerce shipping methods, you can optionally set shipping class costs, i.e. costs that are based on the product shipping class.

Custom Shipping Methods for WooCommerce - Shipping Class Costs Settings

General Options

General plugin options are located in “WooCommerce > Settings > Custom Shipping Methods”.

Custom Shipping Methods for WooCommerce - General Options

Admin Settings: Admin title
Sets custom shipping’s admin title. Visit “WooCommerce > Settings > Shipping” to set each method’s options.
Default: Custom shipping
Frontend Settings: Trigger checkout update
Will trigger the checkout update on any input change. This is useful if you are using cost calculation by distance to the customer.
Default: no
Frontend Settings: Add to zero cost
Will add text to custom shipping cost on frontend in case if it’s zero (i.e. free).
Default: no
Frontend Settings: Add to zero cost: Text
Text to add to zero cost. Ignored if “Add to zero cost” option above is disabled.
Default: None
For example:

<span style="color:green;font-weight:bold;">Free!</span>
Icons & Descriptions: Enable section
Enables icons and descriptions options for custom shipping methods. Visit “WooCommerce > Settings > Shipping” to set each method’s icon and description.
Default: no
Icons & Descriptions: Icon template
Sets template for the icons. Replaced value: %icon_url%.

<img style="display:inline;" src="%icon_url%">
Icons & Descriptions: Description template
Sets template for the descriptions. Replaced value: %desc_text%.

<p style="font-size:small;font-style:italic;">%desc_text%</p>
Icons & Descriptions: Final template
Sets final template. Replaced values: %icon%, %label%, %desc%.

2 reviews for Custom Shipping Methods for WooCommerce

  1. blank

    Luis Ramos (verified owner)

    Does exactly what it says on the tin. Superb support from Tom. Highly recommended!

  2. blank


    Perfect plugin, just what I needed. And thanks to Tom for quick support.

Add a review

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

109 thoughts on "Custom Shipping Methods for WooCommerce"

  1. Hi Guys,

    I am restricting my options shown to customers based on their distance from our shop.

    I would like them to still be able to see these options, even if they don’t qualify, but for the options to not be selectable, how can I make this happen?

    Also, is it possible to show the customer how far away they are from the shop next to the shipping method? We use another plugin where this is possible, so hoping there’s a variable/short code we could use to pull this info through too?


    1. Hi Danny,

      For showing options & making them unselectable:
      This will need modifications to be done in the way the plugin returns the options. It is not possible out of the box.

      For showing how far the customer is from the shop:
      This isn’t possible to show from the plugin currently. As a first step, that requires enabling the Google Distance Matrix API for your account. This too would need changes to be made in the plugin in order to show the distance besides the shipping method.


  2. Hi I need to understand if your plugin can do this:

    A user put in the cart some products in the checkout phase when system add shipping costs I need to add shipping cost in this way:
    If in the cart, the total weight is greater than the total volume use a shipping method if viceversa use another shipping method

    This help me with shipping carrier because I can have prooucts very light weight but with big volume or products with small volume but high weight

    So I need rules and condition to add shipping cost according the comparison between weight and volume

    Please let me know also if you have.another suggest to workaround this

    1. Hello Jack, It is currently not possible to add rules & conditions based on item weight & volume. I am unaware of any workaround that you could use to get this done.


  3. Hi I am trying to set up a cost table with these parameters, I am just not sure how to write this out.

    Wholesale Shipping
    0-$800 | .08*[cost]
    $801+ | .04*[cost]

    1. Hi, Apologies for the late reply.

      Here is how you can implement it: – 10% of total cost for order totals between $0 to $30. – 4% of total cost for order totals above $31.

      Here is the formula: [costs_table prop=”cost” table=”0-.10*[cost]|31-.04*[cost]”]

      I hope this helps.

    2. Hi i want add kilometers to email template “order complete” how i do this?

    3. Hi Peter, It is not possible to add kilometers in the email template.

  4. I have a somewhat unusual shipping need. For anything within 25 miles of the store, we charge a flat fee. After that, it’s $3/mile for both deliver and pickup. So, over 25 miles is $3/mile * 2. Possible with the plugin?

    1. Hi Sean, It is not possible to set a per mile price with the plugin. You can set different prices for a range of miles.


  5. Hi Team,
    Is it possible to integrate Woocommerce Shipping classes with your plugin? I provide food delivery as well as pickup services. I have setup “Local Pickup” shipping class on my store. So, basically when customer goes on checkout they need to get two option (Pickup And Delivery). If Is there any way we can integrate your plugin with WooCommerce Local pickup shipping methods .

    1. Apologies for the late reply. Our plugin does work with the WooCommerce shipping classes. You can enable the custom shipping method to be shown only for selected shipping classes.

  6. Hi
    I am looking for a plugin that will reliably calculate a shipping rate base on the distance from my shop. I therefore can’t use your free version to test it out as it doesn’t offer the function that I am after.

    I have tried two different plugins now and neither work One was a premium plugin, and the support was dreadful (not expected when you pay for a plugin) , so I’m a bit worried about paying for another one.

    Will I get prompt support if I struggle with the set up of this plugin? If it doesn’t work, will I be refunded?



    1. Hi Becky, We do offer prompt support for our plugins. And also we have a 30 day refund policy.

      You can reach out to our support through this page or directly drop an email on our customer support email address at: [email protected]


  7. Hey guys, great plugin, i hope you are all well.
    Currently when users put in their address it is calculating the quickest route using time. Is there a way to calculate the shortest distance even if it takes longer?

    1. Hi, We are doing good. I hope you’re doing well too.

      I think what you’re asking is to give priority to the distance criteria over time. That is currently not possible as we are showing the route as returned from the Google Distance Matrix API.


    2. Thanks for the reply. Do you know how to change this in the google distance matrix api? Or if its possible?

  8. Hi, how to implement both of these at the same time :
    -Costs Table by Distance
    -Costs Table by Order Amount

    -If the customer orders ABOVE a certain amount and the shipping distance is BELOW 10 km, the shipping fee is waived
    -If the customer orders ABOVE a certain amount but the shipping distance is ABOVE 10 km, the shipping fee is still based on the costs table by distance
    -If the customer orders BELOW the minimum amount, the shipping fee is only based on the costs table by distance

    1. Hi, Apologies for the late reply on this one. It is not possible to have the combinations that you mentioned without customizing the plugin.


  9. How do I add a description per shipping method created?

    I purchased PRO as it said it was enabled in this but still do not see the option to type a description per each method.


    1. Hi Ged,

      First, you need to enable the Icons & Descriptions from the Icons & Descriptions Settings at WooCommerce > Settings > Custom Shipping Methods:

      Once that is done, you can set the Method icon & Method description fields for each custom shipping method from the WooCommerce > Settings > Shipping > Shipping Zones section:

      I hope that helps.


  10. I have purchased the plugin and it is very handy.

    I need to set a particular product to be hard set for it’s shipping, but let others calculate by several other rules.

    I have the others all working well…. but how do I set just this one product as follows:

    1 bottle – shipping is $12
    2 – 12 bottles – shipping is $6 EACH??

    I have been and am still trying to find a way to accomplish it but it seems to be pretty tricky.


    1. Hi Mark,

      I am glad you like the plugin.

      This is how you can set $6 each for varying quantities between 2 to 12:

      [costs_table prop=”qty” table=”0-12|2-12|3-18|4-24|5-0″]

      For quantity 1 & 2, it will charge the same shipping amount, which is $12.

      Quantity 4:
      Quantity 1:

      I hope this helps. The example shows for upto 4 quantity. You can repeat the same for upto 12 quantity.


  11. The plugin is working perfectly, great work.

    I currently have 3 delivery options, 0-4km is $3 shipping, 4-8km is $6 shipping and 8-12km is $9 shipping. Do you know a way that i can implement different delivery date options depending on the distance of the user?

    For example:
    0-4km delivery date options: friday or saturday.
    4-8km delivery date options: saturday
    8-12km delivery date options: sunday

  12. Hi guys,

    Fantastic plugin that has worked great for me till recently, thanks for making it.

    If you guys can help me iron out the glitches that have been occurring since a few weeks, I would greatly appreciate it and will immediately buy the pro version to show my support.

    I use the plugin in the following way on

    7*[distance key=”AIzaSyBWhSL0atD3YZrO0vjiWHYPDwwVwVQlFZI” src=” default_distance=”2″ debug=”yes” units=”km” min_distance=”3″ max_distance=”35″]

    For example I had a customer order from 8 Victoria Avenue, Cape Town, Western Cape, 7806.

    If I put in that address it comes up with a delivery fee of R119.79, however if my customer fill the same address in there, it gives her a R14 delivery fee. As you can see from this, this is what I’ve copied from the confirmation email:

    Shipping: R14.00 via On Demand Delivery

    8 Victoria Avenue
    16 Pearl of Hout Bay
    Cape Town
    Western Cape

    I can’t recreate the customer’s experience however! If I look in the debug log I can’t find that address entry anywhere nor any at any other time.

    Any idea? I’m lost!

    1. Hi James,

      That’s rather odd. I have a few questions:

      1. Is this happening only for this 1 address or for some other addresses too?
      2. When you put in this address, are you logged-in as admin?
      3. Since when is this happening? Did a plugin get updated on the site after which this started happening?


  13. I created a table based shortcode for a specific product ID with two prices.

    [costs_table prop=”qty” table=”1-29.95|2-48.75″]

    The next shipping method I added i set the rate to one flat cost regardless of quantity. When both products happen to be in the cart it counts them both as the cost table shortcode even though the second product should not be. Is there a way to fix this?

    1. Hi Kathryn, The shipping method that you added for the 2nd product, is that also created from the custom shipping methods plugin? This shouldn’t be happening.

    2. Yes both are created in the custom shipping plugin. It only allows me to specify “apply this shipping if this product is in the cart” but no conditionals as to what happens when two products are in the cart that are both supposed to have custom shipping.

  14. Hello, I came across this wpfactory plugin in the internet. My question is can the plugin calculate shipping based on vendors location to customers location and the weight of the product and parameters that are over the stipulated weight by the store (Admin). If possible I will need to talk to you on the phone.

    1. Hi, It is not possible to calculate shipping based on location of vendor.

  15. Everything works so far, except that no matter what settings I use, the plugin assumes a default base of $4 for my shipping cost, and then adds the custom shipping cost on top of that. I can’t figure out where that $4 is coming from and where to change that setting.

    1. Hi Maria, Does that $4 shipping cost go away when you deactivate the Custom Shipping methods plugin? Did you check your WooCommerce shipping settings for the $4?

  16. Dear Sir and Madam,

    i have the issue since upgrading WordPress to 5.4 and Woocomerce 4.01 that the max distance value isn’t passed through the methods.

    2020-04-30T13:26:27+00:00 INFO Shortcode `distance`: Atts: Array
    [min_distance] => 0
    [max_distance] => 0
    [default_distance] => 0
    [default] =>
    [units] => km
    [src] =>
    [key] =>
    [rounding] => none
    [rounding_precision] => 2
    [debug] => yes

    Can you help me to get your plugin running again?
    Best reagards
    Anne K. Frey

    1. Hello Anne,

      That’s odd. Are there any errors that you see in the error logs? Is the plugin currently active on your live site? If yes, can you send me the parameters which can allow me to see the custom shipping method on your checkout page?


    2. I wrote you an E-Mail.

    3. Hi Anne,

      Just replied to your email.

  17. Hello,

    I allow myself to contact you because I am trying to configure this plug-in but being currently still a novice because it is currently my first site that I do myself and more extensive French language I go through Google translation to get answers but not always easy to understand these translations not always right.

    My problem is probably something easy to solve.

    I just want to provide free delivery up to a distance of 30Km and beyond that it is simply factor at the current rate of 40.-

    To do this I tried these 2, the first of which had been proposed to me by a friend

    [costs_table prop = “distance” table = “0-10 | 50-50 | 100-125.5” key = “AIzaSyAH2-qfldHNNLS_QhgQv40n6Dy9Y9P4gnA” default_distance = “30” units = “km”]


    1.5 * [distance key = “AIzaSyAH2-qfldHNNLS_QhgQv40n6Dy9Y9P4gnA” default_distance = “20” debug = “yes” units = “km”]

    but that doesn’t seem to be past or is the error.

    thank you in advance

  18. Hello, I’m trying to add Shipping cost by quantity for 1 specific product. Here is the quantity range.
    1 – $3
    2-4 – $6
    5-9 – $8
    10-14 – $12
    15-20 – $15
    Above 20 – $18

    If this is possible how can this be done?

    I did something like this but it didn’t work. A flat rate that is already set for other products is the only shipping that shows on the checkout page. Maybe I did not add it to the right place.
    [costs_table prop=”qty” table=”1=3.00|2-4=6.00|5-9=8.00|10-14=12.00|15-20=15.00|20=18.00″]

    Am I making sense about what I am trying to do?

    1. Disregard this question…I figured it out.

    2. Hello Lance,

      From what you shared earlier, it should have worked with this shortcode [costs_table prop=”qty” table=”1=3.00|2-4=6.00|5-9=8.00|10-14=12.00|15-20=15.00|20=18.00″]

      Could you let me know what was the issue & how did you make it work?


    3. I had set up the Shipping Method incorrectly. I initially set up a new Shipping Zone which is why I wouldn’t show. I realized I just needed to set up a new Shipping Method within the Shipping Zone that has the Flat rate shipping method so they would show together.

      I also tried this which worked [costs_table prop=”qty” table=”1-4|2-7|5-9|10-13|15-16|21-19″]. It probably would have worked using the initial shortcode I was trying to use but because the Shipping Zone not being set up right it wasn’t showing up.

    4. Thank you Lance.

  19. hey is that possible to calculate both item weight and distance
    let’s say for every 5 KM an order weight 2 KG will charge 10 dollars
    then for 10 KM an order weight 4 KG will charge 40 dollars

    1. Hi Chris, It is not possible to calculate the shipping based on a combination of any 2 parameters (or props as we call it). Currently it only supports a single parameter.


  20. HI.
    I am wanting to set the plugin to work so that….

    O to 10 miles is free
    10 miles to 20 miles is £5.00
    20 Miles to 30 Miles is £7.50
    30 Miles+ – No Delivery, Collection only.

    Can this be done?

    1. Hello Tom,

      Yes, this can be done. However, for 30 Miles+, it is not possible to set Collection only. The plugin shall allow you to set shipping costs by distance, but you cannot enable or disable shipping methods based on distance.


  21. I’m having issues first with new custom shipping method show on our website.

    [costs_table prop=”distance” table=”9-10|15-15″ key=”BIzbSyBNBNR9yi3vTgC33oXSpwQftScNSmO-fjc” default_distance=”15″ units=”mi” debug=”yes”]

    1. I was able to figure it out. Needed to add a distance logic code and modify my table distance in one spot.

    2. Hey Kevin, That’s great. I am glad you were able to figure it out. 🙂


  22. Hi,
    I just bought this plugin and I can’t make it work with the distance shortcode. No matter what I do it never picks up the distance between the customer and store. This is supposed to happen right?
    I’m using this shortcode:
    2*[distance key=”MY API KEY” default_distance=”15″ debug=”yes” units=”km”]
    This should mean that for each mile between the store and the customer the shipping should charge 2. So if I was 40 miles away from the store and I placed an order it should calculate it at 80, right? No matter what I do, it’s always calculating 2 * the default distance. It never, never picks up the distance from the customer.

    1. Hi Luis,

      First of all – is possible, please share an admin account to your site, so I could log in and check what’s going on (my email is [email protected]). Let me know if sharing an account is not an option and I will try to solve this remotely.

      Now a couple of notes:

      1. As you have added debug="yes" to the shortcode, you can check what’s going on in “WooCommerce > Status > Logs”. That should give you an idea of what’s happening with distance calculation.

      2. In your shortcode you are using kilometers, not miles. So if you need miles, you need to replace units="km" with units="mi".

      3. Just to be sure that your shop base address is retrieved correctly, you can also try adding src attribute to the shortcode, in this format: src="address, city postcode, country".

    2. Hi Tom,

      Nevermind, my bad. I just noticed the plugin doesn’t work if you set referrers on the Google Cloud Platform. All working now!

      Thanks for your fast reply, anyway. Superb support!

    3. Happy to help and glad to hear you’ve figured it out. Please let me know if you need anything else.

  23. Hi I want to do the following and have tried but cannot figure it out.

    Delivery restricted to 5 miles and if over then no only collection, under £8 charge of £1.25 and over £8 charge of £0.75 can you let me know how this can be achieved as I have tried below and does not seem to work

    [costs_table prop=”cost” table=”0-1.25|8-0.75″ distance key=”MYKEY” default_distance=”5″ debug=”yes” units=”mi”]


    1. Hi Mohammed,

      If I understood you correctly – you need distance for shipping method availability only and not for price calculation, correct? If that’s so – this is not possible at the moment but seems like a useful feature, so please give me a couple of days to add it to the plugin.

      P.S. As for cost calculation, your formula seems correct, i.e.:

      [costs_table prop="cost" table="0-1.25|8-0.75"]
    2. In case if anyone else has a similar question – since plugin v1.5.2, you can now set “Min distance” and/or “Max distance” options in the “Availability” section for each custom shipping method. So in case if you need to restrict shipping to distances below 5 miles, you need to set the “Max distance” option to 5 and “Distance calculation” option to something like:

      [distance key="YOUR_KEY" units="mi" debug="yes" default_distance="5"]
  24. I’ve purchased two plugins for my website with the intention of charging a delivery fee based on distance (miles), and they have not worked. Will this plugin for sure work on my website? I’m afraid of buying another plugin and it not working.

    1. Hi Roy,

      I can confirm that it’s working. Also, if you wish, I can log in to your site and help you setting up the plugin, in case if you have any questions/issues.

  25. I have set a minimum shipping cost of £2.50, can I set an additional shipping price for orders over £25.00 with the free version?

    1. Hi Allan,

      Sorry for the late reply.

      Not sure if I understood the question correctly, but if you are using the free version, you could add two different shipping methods with different shipping costs and use “Min cart cost” and “Max cart cost” options in each method’s “Availability” section to display only one shipping method at frontend depending on order total (i.e. cart cost). Hope you get the idea…

      Hope that helps.

  26. Hi,
    I am not sure if I am missing something but can’t work out the GST (Goods & Service Tax) for the shipping method.
    My store currently has product prices that have tax included (by law in Australia this is needed). I have added a lot of code for all different postal zones in Custom Shipping Method and added the shipping prices GST included (as per the rest of the shop). Problem is that in when I add Tax Status (Taxable) it adds tax to that shipping making the cost of shipping too much. I have tried to change WooCommerce > Tax Options for shipping but nothing I do makes the figure GST inclusive and added to Taxable total.
    Does Custom Shipping Method’s shipping costs need to be added in ex-tax, then taxable selected? So opposite to how I have the woocommerce product tax set up?

    One zone has these custom shipping prices:
    [costs_table prop=”qty” table=”0-15.35|11-19.95|13-21.40|15-22.85|16-33.00|31-34.45|33-35.90|35-37.35|37-38.80|39-40.25|41-55.60|51-60.20|53-61.65|55-63.10|56-73.25|71-74.70|71-74.7|73-76.15|75-77.60|77-79.05|79-80.50|81-95.85|91-100.45|93-101.90|95-103.35|96-113.50|111-114.95|113-116.40|115-117.85|117-119.30|119-120.75|120-120.75″]

    12 zones all with that amount of prices, this is why i don’t want to change GST amounts for all shipping.

    1. Hi Valentino,

      If I understood it correctly – yes, custom shipping cost should be set without tax. If you check the description tip near the “Cost” option, it says “Enter a cost (excl. tax) or sum…”. Generally, we did that because the same cost settings rules are used in standard WooCommerce “Flat rate” shipping settings (i.e. also excluding tax).

      Not sure if it will help, but you don’t want to change all the prices, you could just divide the final value to exclude the tax. For example, if your tax is 20%, then you could just add /1.2 at the end of your formula, i.e.:

      [costs_table prop="qty" table="0-15.35|11-19.95|13-21.40|15-22.85|16-33.00|31-34.45|33-35.90|35-37.35|37-38.80|39-40.25|41-55.60|51-60.20|53-61.65|55-63.10|56-73.25|71-74.70|71-74.7|73-76.15|75-77.60|77-79.05|79-80.50|81-95.85|91-100.45|93-101.90|95-103.35|96-113.50|111-114.95|113-116.40|115-117.85|117-119.30|119-120.75|120-120.75"]/1.2

      Hope that helps.

  27. I’m hoping you can help me with an issue I’m having. I have a few products with a free shipping class, however the custom distance delivery price still shows on these products as an option for shipping? Can you please show me how to overcome this?

    Many thanks in advance,

    1. We did solve it privately, but in case If anyone else has a similar question – the solution was to move shipping cost calculation formula from general “Cost” to “No shipping class cost” option.

  28. Hi,

    I would like to add a maximum limit to my shipping price.

    I tried that with the “max cost limit” option but it’s not working.

    Waiting for your advices.


    1. In case if anyone else has a similar question – the problem was in product shipping class usage. In plugin v1.4.2 we’ve added a new “Limits calculation” select option to “Shipping class costs” settings section. This option has three possible values:

      * Per class: Check limits for each shipping class individually (default)
      * Per order: Check limits for final cost only
      * All: Check limits for each shipping class individually and then for final cost

      Switching it either to “Per order: …” or to “All: …” solved the task.

  29. Hi, I’ve just bought the shipping distance plugin. I’m really sorry but I have no idea how to implement this on the website. I just want these basic rules setting up: 0-25 MILES FREE, 25-50 MILES £30, 50-75 MILES £50, 75-100 MILES £75 100+ MILES £100

    Can you please instruct me how? Your help would be greatly appreciated.

    Thank you,


    1. Hi Dan,

      Here the shortcode you need to put in your custom shipping’s “Cost” field:

      [costs_table prop="distance" table="0-0|40.2336-30|80.4672-50|120.701-75|160.934-100" key="AIzaSyC4OkGgzRYLc80yEYzuhU7USYFzwXzzzzz" default="100" units="km"]

      The most important thing – you need to replace key (i.e. AIzaSyC4OkGgzRYLc80yEYzuhU7USYFzwXzzzzz) with your own key, you need to get from – it’s free.

      Also, as you can see, I’ve replaced miles with distances in kilometers (25 miles = 40.2336 km, 50 miles = 80.4672 km, 75 miles = 120.701 km, 100 miles = 160.934 km). If that’s an issue – I can add miles to our plugin today. This won’t be hard to do.

    2. Hi again, Dan,

      Just wanted to let you know that we’ve released new plugin v1.4.0 today, where I’ve added miles (mi) to the [costs_table] shortcode, so now you can set:

      [costs_table prop="distance" table="0-0|25-30|50-50|75-75|100-100" key="AIzaSyC4OkGgzRYLc80yEYzuhU7USYFzwXzzzzz" default_distance="100" units="mi"]

      Also, I’ve noticed that you may need to enable “Trigger checkout update” option in “WooCommerce > Settings > Custom Shipping Methods”, so that shipping cost is updated immediately if a customer changes his address on the checkout page.

      And last note – if you want to show shipping cost only after customer has entered his address, you may want to enable “Hide shipping costs until an address is entered” option in “WooCommerce > Settings > Shipping > Shipping options”.

  30. Good evening,
    I am looking for a solution to deduct the cheapest shipping costs if a customer buys 4 items.
    Deduct the least expensive flat price on the purchase of 4 products in are basket.
    Do you think this is possible with your plugin
    Thank you in advance for your answer
    Thank you

    1. Hi Alan,

      I’m not sure if I understood the task correctly. Do you mean that if, for example, the customer adds 4 products (product A, product B, product C and product D) to the cart and if, for example, product’s A price is the lowest of 4 products, then we need to deduct product’s A price from the totals, is that correct?

    2. Hello,
      it is exactly that
      you have understood very well,
      I can not find a solution to this problem
      Clients often have requests that are not expected
      Sorry to get back late
      Thank you

    3. Hello,
      I think I was a little fast.
      The idea is to deduct the cheapest shipping price on 4 purchases made. Each product has a flat rate shipment.

      this is possible
      Thank you

    4. Hi Alan,

      I’m sorry but I’m still not sure if I understand it correctly. Maybe you can give me an example? And by “… on 4 purchases made…” – do you mean 4 different orders?

    5. Hello,
      Let’s take an example
      I order :
      • a product A – (fixed price € 2)
      • a product B – (fixed price of 3 €)
      • a product C – (fixed price 4 €)
      • a product D – (fixed price 5 €)
      Normally I will have to pay in Postage 2 € + 3 € + 4 € + 5 € = 14 €
      But as I ordered 4 products – I would like to remove the price of sends the cheapest one ie 2 €
      If who makes 3 € + 4 € + 5 € = 12 €
      Sorry to mis explain me
      Thank you

    6. Hi Alan,

      By shipping’s “fixed price” for a product – you mean you are using product “shipping classes”, correct?

    7. Good evening,
      yes I use “shipping classes” of the plugin to set lump sum shipping prices

    8. Hi Alan,

      Hopefully I’ve understood you correctly. First of all – please update to the latest plugin version 1.4.0 that we have just released. Now as your task is rather specific, I’ve decided to add a filter, so you could add a PHP snippet to your site. The snippet is in the “Developers” tab on the current page. Please take a look and let me know if something is not working as expected or if you have any questions.

      P.S. And if you like the plugin, please consider leaving me a rating.

    9. Too bad not being able to put six stars to this awesome plugin.
      I searched a lot of plugin for functions
      dispatch management.
      Custom Shipping Methods for WooCommerce is the best.
      Thanks Tom

    10. Thank you, I really appreciate it!

  31. Hi,
    since the last update (1.3.1),
    the plugin malfunctions, I can’t select the option “based on”
    So, my delivery options aren’t found…
    Can you help me please ?

    1. Hi,

      Thanks for reporting, however, I’ve just tested it on my server but unfortunately couldn’t reproduce the issue – custom shipping seems to be working fine here. I’m not really sure I understood “based on” option – where is this option located?

      P.S. If you wish you can create/share an admin account to your server so I could log in and check what’s going on (my private email is [email protected]).

  32. Hi Tom,

    Wondering if your plugin can provide this level of shipping customization

    First class shipping $3.50 for the first item and $1.00 for each additional item
    Priority shipping $8.50 for the first item and $3 for each additional item
    Overnight shipping $25 for the first item and $9 for each additional item

    International shipping $14 for the first item and $8.50 for each additional item

    1. Hi Chris,

      Yes, that is possible. You need to add 4 custom shipping methods and for each set Cost accordingly:


      Hope that helps. Please let me know if you have any questions.

  33. Hi, just got the plugin installed but it does not seem to work, I sure I am missing some thing. here is the code I used
    [costs_table prop=”cost” table=”0-29.99|7.99-49.99|9.00-74.99|13.99-99.99|17.00-149.95|21.99″]

    looking for this
    We offer free shipping on orders of $150.00 or more.
    Our shipping chart is as follows.

    0.00 – 29.99 $7.99

    30.00 –49.99 $9.00

    50.00 –74.99 $13.99

    75.00 —99.99 $17.00

    100.00—149.99 $21.99

    testing can be done at cart is live

    1. even as a programmer I find the rates hard to understand I would expect or like to see something easy like

      [costs_table prop=”cost” table=”0-29.99=7.99|30.00-49.99=|9.00|50.00-74.99=13.99|75.00-99.99=17.00|100.00-149.99=21.00″] if you cant use the = since its a operator use- but pipe on each rate.


    2. I re did the code and I am using this now [costs_table prop=”cost” table=”1-7.99|29.99-49.99|9-74.99|13.99-99.99|17-149.99|21.99″] now I get “there are no shipping options available for this address”

    3. Hi,

      Sorry for a late reply. According to your table, I believe what you need is:

      [costs_table prop="cost" table="0-7.99|30-9|50-13.99|75-17|100-21.99|150-0"]

      P.S. “there are no shipping options available for this address” message appears because you need to add some value to 21.99, i.e. it always has to be in min_prop-cost format.

      P.P.S. Regarding your proposed format (...0-29.99=7.99|30.00-49.99=...) – will be trying to add it as an alternative format in next plugin version.

    4. Hi,

      Just wanted to let you know and if anyone else has similar questions – as requested we have finally added an alternative table format to the [costs_table] shortcode. You need to add table_format attribute to the shortcode and set it to range, e.g.:

      [costs_table prop="cost" table="0-30=7.99|30-50=9|50-75=13.99|75-100=17|100-150=21.99|150-=0" table_format="range"]
  34. hi,

    I was wondering if this plug -in can handle different free shipping tresholds. We are sending by post and dhl, however, the treshold for post to be free is of course lower then dhl.



    1. Hi Sam,

      Wasn’t possible, but I’ve just added it to the plugin. After you update to new version 1.3.1, you will find new Free shipping minimum order amount option in methods’ settings. Unfortunately, this option is available in Pro version only.

      P.S. If you are calculating shipping cost based on order cost, you can also use [costs_table] shortcode for minimimum free shipping order amount, e.g.:

      [costs_table prop="cost" table="1-10|10-5|20-0"]

      Hope that helps. Please let me know if you have any questions.

  35. Hello
    How to calculate with a table if we charge client per km of delivery?

    1. Hi Konstantin,

      The idea is really interesting and I would gladly implement it in plugin, however there is one major problem – plugin would need to know the distance between your shop and the customer. For plugin to calculate the distance, it would need to know the coordinates (i.e. latitude and longitude) of both your shop and the customer. In standard WooCommerce setup, customer enters ZIP code, so we could try go get latitude and longitude from ZIP code, but this would definitely require some external API, which would connect ZIP codes with coordinates. If you have any thoughts on how to solve this – please let me know.

      Simple solution would be acceptable if your shop deliver to small (or at least finite) number of ZIP codes – in this case we could manually pre-fill the table of ZIP codes -> distances. Hope you get the idea…

    2. We deliver by cars, cars use roads and only distance we can get – from direction of any mapping service: google, yandex, waze. When you install woocommerce you fill an address of your store/warehouse, when client place order – they fill the address of delivery. When you have 2 addresses you can calculate distance between them with any maps API, google distance matrix for example –
      If you can implement it in a plugin – I’ll be your first client who bought it :)) I think this plugin will be useful for any who make local delivery.

    3. Hi Konstantin,

      We’ve just released new plugin version 1.3.0. As suggested I’ve added calculation by distance, e.g.:

      1.5*[distance key="BIzbSyBNBNR9yi3vTgC33oXSpwQftScNSmO-fjc" default="15" debug="yes" units="km"]


      [costs_table prop="distance" table="1-10|50-50|100-125.5" key="BIzbSyBNBNR9yi3vTgC33oXSpwQftScNSmO-fjc" default="125.5" units="km"]

      Unfortunately both shortcodes went to Pro version only, hope you understand.

      You can read more about these shortcodes in the “Description” tab.

      Please let me know if something is not working as expected or if you have any questions. Any feedback is highly appreciated.

  36. Hi,
    Thanks for this plugin,

    It seems the plugin desn’t consider the included or excluded VAT enter option (first option in Woocommerce > Settings > VAT).
    In fact, I use included VAT prices for my product whereas “Custom Shipping Methods for WooCommerce” still use excluded VAT .
    There is no problem in Woocommerce, but I use a connector with Odoo and it couldn’t understand that there are both included VAT for products and excluded VAT for the ship.

    So is it possible to input included VAT prices for the cost of a custom shipping method ?

    Thank you for your help.

    1. Hi Remi,

      You are correct – custom shipping cost should be set without VAT. If you check the description tip near the “Cost” option, it says “Enter a cost (excl. tax) or sum…”. We did that because same cost settings rules are used in standard WooCommerce “Flat rate” shipping settings (i.e. also excl. tax).

      I could probably add an option to set cost with VAT, however I’m not really sure I understand the task correctly. I mean – you could just precalculate shipping cost manually just once and enter it without VAT (e.g. if shipping cost is $100 with VAT and VAT is 20%, then you would enter 100 / 1.20 = $83.33 as custom shipping method cost) – wouldn’t that solve the issue? What am I missing?

      Also, as you’ve probably noticed, there is “Tax status” option in custom shipping method’s settings, so you can set if final shipping price for the customer should include or exclude VAT.

    2. Hi,

      Thanks for reply.

      I know you did that because same cost rules are used in standard Woocommerce settings.
      I already input shipping cost without VAT, but it’s not my issue.
      In fact, there is no issue with your plugin.
      I’m trying to get around another issue from an Odoo connector, and I think if I could input shipping cost with VAT included, it should resolve a part of the problem.

      And I don’t understand your last sentence.
      Because, the “Tax status” option can set if there is or not VAT for a cost… that’s different than input an included VAT price or an excluded VAT price.

      Certainly my request is not very clear because the goal is to resolve another problem, totally independant of your plugin.
      I only wonder if your plugin could process with an included VAT logic instead of an excluded VAT logic.


    3. Hi Remi,

      Ok – please give me a couple of days to check if I can add an option to set custom shipping cost including VAT. Will get back to you about this asap.

      Regarding my previous note about “Tax status” – you are correct, this sets if VAT should be added to shipping cost in final calculation. Just thought maybe this may help you… Anyway, in case anyone else has question regarding “Tax status”: for example you set shipping cost to $10 and your VAT is 20%, then if you set tax status to “Taxable” you will get $12 as final shipping price and if you set tax status to “None” – final shipping price will be $10.

    4. Hi Remi,

      We’ve just released new plugin version 1.3.0. I didn’t add option to enter price with VAT, however I did add alg_wc_custom_shipping_methods_evaluate_cost_sum_evaluated filter that is applied just before the shipping cost is returned. So now you can modify the cost by adding something like this to your (child) theme’s functions.php file:

      add_filter( 'alg_wc_custom_shipping_methods_evaluate_cost_sum_evaluated', 'custom_modify_shipping_cost', 10, 1 );
      if ( ! function_exists( 'custom_modify_shipping_cost' ) ) {
      	function custom_modify_shipping_cost( $sum ) {
      		if ( WC()->cart->get_customer() && ! WC()->cart->get_customer()->get_is_vat_exempt() ) {
      			$sum = $sum * 1.21;
      		return $sum;

      If you could give more info on when you need to add/remove VAT from cost – I could try to provide you with the exact code to add.

      Also if you wish, you can share an admin account to your site (WP and FTP) so I could login and help you with solving the task – my private email is [email protected]

      Hope that helps.

  37. hello
    Can it display Free instead of 0.00 when there is no cost?

    thank you

    1. Hi Sam,

      Thanks for the idea. Already working on this – will release new plugin version in a couple of hours or so.

    2. Hi again Sam,

      As promised, we’ve just released new plugin v1.2.1 (both Free and Pro). After updating please go to plugin settings (in “WooCommerce > Settings > Custom Shipping Methods”) and enable “Replace zero cost” checkbox there. You can also choose what text to display instead of $0.00: it can be empty (as with WooCommerce standard “Free shipping” method) or you can set some text (can be HTML), e.g.:

       - <strong style="color:red;">Free</strong>

      Please let me know if it’s not working as expected. And if you like the plugin, please leave us a rating.

  38. Hello,
    I bought the plugin “custom-shipping-methods-for-woocommerce-pro” . I want a new custom shipping method and I added it to woocommerce. I want to setup the following costs based on products weight.

    0-750 g 2.6€
    750-1750 g 3.2€
    1750-2750 g 3.9€
    2750-3750 g 4.4€
    3750-4750 g 5€

    I use the following shortcode:
    [costs_table prop=”weight” table=”0-2.6|750-3.2|1750-3.9|2750-4.4|3750-5|4750″]

    The problem is that the costs in the checkout page is 0.00. What I did wrong? Please help.

    Thanks in advance.

    1. Hi,

      There is last price missing in your shortcode (i.e. for the 4750 weight), so please try something like this:

      [costs_table prop="weight" table="0-2.6|750-3.2|1750-3.9|2750-4.4|3750-5|4750-6"]
  39. The costs table feature, the reason I purchased the plug-in, does not seem to work for me at all. Regardless of quantity it always charges the max rate.

    1. Hi,

      Maybe you could send me the exact [costs_table] value you are trying to use? I mean with your prop and table attribute values? Also if you wish you can create/share an admin account to your server (WP and preferably FTP), so I could login and check what’s going on (my email is [email protected]).

    2. In case if anyone else has similar issues – as we’ve figured out in private emails – there was a bug in plugin, which is now fixed in v1.2.0.

Leave a Reply

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


1.6.2 - 18/02/2020

  • Fix - Admin Settings - Text domain fixed.
  • Dev - Availability - "Require type" option added.

1.6.1 - 22/01/2020

  • Dev - Shortcodes - [round] shortcode added.
  • Dev - Code refactoring.
  • WC tested up to: 3.9.

1.6.0 - 30/12/2019

  • Dev - Availability - "Required/Excluded products/categories/tags" options added.
  • Dev - "Free shipping products" option added.
  • Dev - Settings - Icons & Descriptions - Placeholders list added to the description.
  • Dev - Code refactoring.

1.5.3 - 11/12/2019

  • Dev - Shortcodes - [distance] - Caching results now.
  • Dev - Code refactoring.

1.5.2 - 06/12/2019

  • Dev - Availability - "Min distance" and "Max distance" options added.
  • Dev - Advanced - "Custom return URL" option added.
  • Dev - Shortcodes - [costs_table] - Evaluating math expressions in costs now.
  • Dev - Admin settings descriptions updated.
  • Dev - Code refactoring.

1.5.1 - 13/11/2019

  • Dev - Shortcodes - [distance] - Returning default_distance at once when source or destination address is empty.
  • WC tested up to: 3.8.
  • Tested up to: 5.3.

1.5.0 - 23/10/2019

  • Feature - Shortcodes - [distance] - Rounding attributes added (rounding and rounding_precision).
  • Feature - Shortcodes - [distance] - Min and max distance attributes added (min_distance and max_distance).
  • Dev - Code refactoring.

1.4.3 - 03/10/2019

  • Dev - General - Frontend Settings - Add to zero cost - Admin settings descriptions updated.
  • WC tested up to: 3.7.

1.4.2 - 14/06/2019

  • Dev - Shipping class costs - "Limits calculation" option added.
  • Dev - Admin settings descriptions updated ("Free shipping min amount").
  • Dev - Minor code refactoring.

1.4.1 - 25/05/2019

  • Dev - General - Frontend Settings - Trigger checkout update - Now triggering checkout update only on billing_ and shipping_ input change.
  • Dev - General - Frontend Settings - Add to zero cost - Admin settings descriptions updated.

1.4.0 - 24/05/2019

  • Feature - Shortcodes - [costs_table] - table_format attribute added (defaults to min; other possible value: range) (and default_cost attribute added).
  • Feature - Shortcodes - [distance] - Miles (mi) option added to the units attribute (same applies to [costs_table prop="distance" ...]).
  • Dev - General - Frontend Settings - "Trigger checkout update" option added.
  • Dev - Shortcodes - [distance] - default attribute renamed to default_distance.
  • Dev - WC_Shipping_Alg_Custom - alg_wc_custom_shipping_methods_add_rate filter added.
  • Dev - WC_Shipping_Alg_Custom - evaluate_cost() function visibility changed from protected to public.
  • WC tested up to: 3.6.
  • Tested up to: 5.2.

1.3.1 - 09/02/2019

  • Feature - [costs_table] - cost property added (i.e. [costs_table prop="cost" ...]).
  • Feature - "Free shipping minimum order amount" option added.
  • Dev - [costs_table] - Code refactoring.
  • Dev - Admin settings restyled.

1.3.0 - 03/12/2018

  • Feature - "Min cost limit" and "Max cost limit" options added.
  • Feature - [distance] shortcode added.
  • Feature - distance prop added to the [costs_table] shortcode (i.e. [costs_table prop="distance"]).
  • Dev - Method settings descriptions updated.
  • Dev - alg_wc_custom_shipping_methods_evaluate_cost_sum and alg_wc_custom_shipping_methods_evaluate_cost_sum_evaluated filters added.

1.2.1 - 14/11/2018

  • Feature - "Replace zero cost" options added.
  • Dev - Code refactoring.

1.2.0 - 18/09/2018

  • Feature - "Method icon" and "Method description" options added.
  • Fix - [costs_table] shortcode fixed.
  • Dev - Admin settings restyled.

1.1.0 - 14/09/2018

  • Feature - Availability - "Min cost", "Max cost", "Min volume", "Max volume", "Min quantity", "Max quantity" options added.
  • Fix - Core - Checking if product has dimensions before calling get_height(), get_width() and get_length() in get_products_volume().
  • Fix - Core - Checking if product has weight before calling get_weight() in get_products_weight().
  • Dev - Default "Admin title" and "Method title" values updated.
  • Dev - Minor admin settings restyling.
  • Dev - Code refactoring.
  • Dev - POT file added.
  • Dev - Plugin description in readme.txt updated.
  • Dev - Plugin URI updated.

1.0.0 - 09/05/2018

  • Initial Release.

Free version

This plugin is a premium version of free "Custom Shipping Methods for WooCommerce" plugin.


If you need to modify custom shipping method's cost, there is a filter for that:


For example, let's say you are using product shipping classes when calculating shipping cost and you need to deduct the least expensive shipping class amount from the final shipping cost for orders having 4 or more products. This is the code you would need to add to your (child) theme's functions.php file:

if ( ! function_exists( 'my_alg_wc_custom_shipping_methods_deduct_lowest_class' ) ) {
     * my_alg_wc_custom_shipping_methods_deduct_lowest_class.
    function my_alg_wc_custom_shipping_methods_deduct_lowest_class( $rate, $package, $shipping_method ) {
        $min_products_count = 4;// Here you set how many products there should be in cart at least
        if ( ! isset( $package['contents'] ) || count( $package['contents'] ) < $min_products_count ) {
            return $rate;
        $shipping_classes = WC()->shipping->get_shipping_classes();
        if ( ! empty( $shipping_classes ) ) {
            $found_shipping_classes = $shipping_method->find_shipping_classes( $package );
            $lowest_class_cost      = false;

            foreach ( $found_shipping_classes as $shipping_class => $products ) {
                // Also handles BW compatibility when slugs were used instead of ids
                $shipping_class_term = get_term_by( 'slug', $shipping_class, 'product_shipping_class' );
                $class_cost_string   = $shipping_class_term && $shipping_class_term->term_id ? $shipping_method->get_option( 'class_cost_' . $shipping_class_term->term_id, $shipping_method->get_option( 'class_cost_' . $shipping_class, '' ) ) : $shipping_method->get_option( 'no_class_cost', '' );

                if ( '' === $class_cost_string ) {

                $has_costs  = true;
                $class_cost = $shipping_method->evaluate_cost( $class_cost_string, apply_filters( 'alg_wc_custom_shipping_methods_evaluate_cost_args_class', array(
                    'qty'  => array_sum( wp_list_pluck( $products, 'quantity' ) ),
                    'cost' => array_sum( wp_list_pluck( $products, 'line_total' ) ),
                ), $products ) );

                $lowest_class_cost = $class_cost < $lowest_class_cost || false === $lowest_class_cost ? $class_cost : $lowest_class_cost;

            if ( $lowest_class_cost ) {
                $rate['cost'] -= $lowest_class_cost;
        return $rate;
    add_filter( 'alg_wc_custom_shipping_methods_add_rate', 'my_alg_wc_custom_shipping_methods_deduct_lowest_class', PHP_INT_MAX, 3 );

Installation and Updates

  • Buy the plugin 🙂
  • Download plugin's zip to your computer (you will receive an email with download link, or you can always download the plugin from your account).
  • Go to "Admin Dashboard > Plugins > Add New > Upload Plugin" and browse for downloaded zip file.
  • If plugin is successfully installed - you should see it added to the Plugins list.
  • To keep WPFactory items up to date, please install WPFactory Helper plugin and enter your site key.


We want to ensure that you are 100% happy with your purchase, so if you feel the product(s) you purchased are not the best fit for your requirements and you attempted to resolve issues with product's author, we are offering 30 day money back guarantee refund policy.