20170211
Investigating WordPress Woocomerce for calculating shipping
Reminder of our fundamental package principles
- Adapt to use vanilla (non plugin) functionality where ever possible
- Minimal customisation, & minimal use of plugins for:
- cost
- ongoing maintenance re managing regression testing of updates
- risk re future compatibility issues
- reduce security footprint
Client shop considerations
- Some products are sold by the mm, customer can select from a fixed set of sizes
- Products are heavy
- Can’t afford to offer free shipping
- Geographical limitations
- North vs South Island so inter island is more expensive
- Additional surchage for rural addresses
- Resolves to these variants:
- North Island Urban
- North Island Rural
- South Island Urban
- South Island Rural
- Need to keep shipping as low as reasonably possible to encourage cart conversions, so can’t offer a flat rate
Woocommerce shipping options analysis
Reminders:
- Shipping Zone -> Methods = Rates (shipping cost)
- “Your customers will only see the methods available for their address and corresponding zone. (Each customer matches only one zone)”
- Shipping calculator in shopping cart is specifically to facilitate matching the customer to their shipping zone
Options
Here we make a decision with associated trade-offs:
- We have one zone for all of New Zealand:
- Pros:
- No need to wait for customer to enter address for us to show shipping costs
- Simplest setup
- Cons:
- Customer needs to select the shipping option relevant to them, if they select wrong then fulfillment costs go up as shop staff chase the correct charge with the customer
- Pros:
- We have multiple zones based on Post Codes
- Pros:
- The correct shipping charge is calculated, and the customer only sees shipping methods applicable to them
- We could present better prices for customers in our local, inner regional, regional area
- Cons:
- Setup & maintenance
- Customer needs to enter postcode into shipping calculator if not logged in
- Shipping calculator in cart is clumsy for us as asks for both ‘State’ and ‘Postcode’
- We would need to hide the ‘State’ selector’
- Shipping calculator in cart is clumsy for us as asks for both ‘State’ and ‘Postcode’
- Pros:
- Multiple zones based on States (Possible option, untested)
- We replace current states with:
- North Island Urban
- North Island Rural
- South Island Urban
- South Island Rural
- Needs to be tested as possible conflict with Address entry
- Pros:
- Same as 2 above but less maintenance
- Cons:
- Shipping calculator to be tweaked to hide ‘postcode’ element
- We replace current states with:
Conclusion: Option 1
- Justification:
- We anticipate a low level of sales of rural addresses
- Simplest setup
- Results in:
- We only have one Zone: = All of NZ
- NZ Zone has multiple shipping methods+calculated shipping cost, presented to the customer as options for them to choose from
- The shipping calculator is disabled
Flat Rate Box plugin + compatibility
As Woocommerce vanilla shipping options are very limited, we have to use a plugin.
Its function is to calculate ‘rate’ (shipping cost) per each ‘shipping method’ (shipping option) within the customers ‘shipping zone’
The flat Rate box plugin:
- Requires all products sold to have a full set of per unit dimensions:
- Length, Width, Height, Weight
- When the cart is viewed & at checkout:
- Runs an algorithm to determine the shipping options/cost
- Per the products & quantities in the shopping cart, matched to the per unit product dimensions
- Per the customers ‘Shipping Zone’ (only one zone is matched per customer)
- For each ‘Shipping method’ in the customers zone:
- Runs an algorithm to determine the FIRST (top down) matching set of box dimensions
- Result of the algorithm is a single $shipping cost
- For each ‘Shipping method’ in the customers zone:
- Presents the named Shipping method along with the found $shipping cost as a selectable customer option
- Runs an algorithm to determine the shipping options/cost
Compatibility issues:
We had previously setup the Measurement price calculator plugin for allowing customers to select required lengths for relevant products. We then tested with the Flat rate box plugin installed.
As at 20170214 Measurement Price Calculator plugin IS NOT compatible with Flat Box Rate plugin
- Basically in testing it appears it is not passing the length selected to the Flat rate Box plugin
Solution:
- Removed Measurement price calculator and reverted to using product variations instead to allow shop customers to choose product lengths for those applicable:
- Cons:
- No automatic inventory management for those products.
- Pros:
- One less (complex) plugin for both cost & future regression testing of updates to WordPress / Woocommerce / Plugins
- Overall I see this as a win
- We had other initial compatibility issues with the Measurement price calculator plugin. This had already made me uncomfortable re increased risk around future incompatibility
- There are only a few products sold by length and they are so large physical stock take is relatively easy.
As at 20170214 Standard product variations (by length) are compatible with the Flat rate Box plugin
- In testing we proved product variations are correctly passing variation length to the Flat Rate Box plugin as expected. This will be an important future regression testing scenario
Other observations
About the Flat Rate Box plugin discovered during initial exploratory testing:
- If it cannot find a single match, it will select combine hits to fulfil the order
- e.g. we might get returned the price for 1 x PE + 1 x SG tickets if the order is large enough
Poste Haste courier ticket options analysis
We have selected Poste Haste couriers.
Observations
(Poste haste maximum package length is 1.75m so we will limit our customer choices to a maximum of 1.7m)
Looking at Post haste rate card & ticketing guidelines for our region, we see different tickets across these variables:
- Geographic:
- Same Island (North): Local link: immediate local area
- Same Island (North): Outer Area: larger local area
- Same Island (North): Regional link: local region
- Same Island (North): Outside our region
- Same Island (North): Rural delivery add on ticket
- Other Island (South)
- Other Island (South): Rural delivery add on ticket
- Ticket physical constraints
- Express envelopes various physical sizes + max weight
- Tickets: various max weight volume
Looking to achieve the generally lowest shipping rates possible to avoid cart abandonment, we observe:
- Our products are heavy by volume, so we will usually run into weight limits on each ticket before volume limits (Update: I have since tested this theory after completing the setup documented herein and it was a valid assumption)
- SG Signature Express small parcel ticket price ships same quantity more or less as all but the smallest 3 express packs, so other than the convenience of a bag, no need for the larger, more expensive express packs
- For the South Island, the NE Inter Island Express is very pricey for larger orders (again, as we are shipping reasonably heavy items) but they do also offer a (slower) TD Two Day Inter Island Express variation for 66% the price of the NE ticket, to allow for this we will provide a second set of options for South Island customers
Compromising the above principle re presenting lowest prices:
- We simplify Same Island (North) to 1 Geographic area:
- Same Island (North): Outside our region
- This is a consequence of choosing option 1 in our Woocommerce shipping options analysis above
Shipping methods with Tickets selections
After going through the options for the same island (North) we are looking to simplify down to 2 shipping methods:
- 1. North Island Urban
- Express pack letter
- Express pack small
- Express pack priority despatch
- SG Ticket Small parcel max 5KG + 0.015m3
- PE Ticket Intra island Express max 10KG + 0.03m3
- 2. North Island Rural
- As above with addition of price for RZ Rural delivery ticket
For the South Island we will offer an initial 2 shipping methods reflecting the equivalent North Island options per above:
- 3. South Island Urban
- Express pack letter
- Express pack small
- Express pack priority despatch
- SG Ticket Small parcel max 5KG + 0.015m3
- NE Ticket Inter island Express max 10KG + 0.03m3
- 5. South Island Rural
- As above with addition of price for RZ Rural delivery ticket
We will also offer the TD ticket as separate options:
- 4. South Island Urban (Two Day)
- TD Two Day Inter Island Express
- 6. South Island Rural (Two Day)
- TD Two Day Inter Island Express + RZ Rural delivery ticket
Methods 4 & 6 are confusing for customers when shipping rates for other options are low but make more sense for larger orders as then have a significant saving in shipping cost
Delivery expectations:
Poste haste documentation is a little inconsistent re South Island delivery times so the shop will provide these promises to customers:
- North Island
- Next day shipping
- Overnight delivery for non rural
- Rural can be a few days..
- South Island
- Next day shipping
- 2 day shipping for non rural but often overnight
- Rural can be a few days..
- South Island TD option:
- Next day shipping
- 3 day shipping for non rural but often overnight
These are conservative timings, as we get actual tracking data we can potentially revise these in the future.
Customer help
Need to add a page to the shop explaining shipping methods & expectations
Dimensions per ticket for the Flat rate Box plugin
For each possible ticket per each shipping method we need to enter the ticket dimensions:
- Length
- Width
- Height
- Max weight
For max weight, I enter the allowed weight less 0.5KG to allow for packaging
Express packs
Express packs are flat envelopes, we inserted various sized boxes into each to determine an effective box volume.
- e.g. Express small letter is 260x150mm, we determined that it can comfortably (with an allowance for bubble wrap etc) take a cubic volume of 180mm x 70mm x 50mm
- Maximum weight is 5kg so we enter 4.5 kg to allow for packaging
Cubic volumes for freight tickets
When selling small items we can get away with entering a single set of dimensions per ticket, which totals to the tickets allowed cubic volume. However, as we are selling variable lengths, we need to get a higher degree of matches for a lower priced ticket across varying maximum product lengths per order.
Considering the SG ticket where constraint is 0.015m3 & max 5KG (and in this analysis, for simplicity, ignoring any allowance for packaging)
- If we enter the SG ticket dimensions as dimensions as:
- L=1m x W=0.1m x H=0.15m = 0.015m3
- Then:
- Lengths of > 500mm to 1000mm will only fit once (long wise)
- Lengths > 1000mm to our maximum won’t fit at all
So although I’m actually not sure how much this is really required, my instinct is that to increase the likelihood of an efficient match to the inefficient Flat Box Rate binning algorithm I enter multiple boxes per ticket, increasing in length.
So for our SG ticket I enter these boxes per method:
Units | L | W | H | Calc m3 |
m | 0.3 | 0.22 | 0.22 | 0.01452 |
m | 0.5 | 0.1 | 0.28 | 0.014 |
m | 0.6 | 0.1 | 0.235 | 0.0141 |
m | 0.75 | 0.1 | 0.185 | 0.013875 |
m | 1 | 0.1 | 0.135 | 0.0135 |
m | 1.1 | 0.1 | 0.125 | 0.01375 |
m | 1.2 | 0.1 | 0.115 | 0.0138 |
m | 1.3 | 0.1 | 0.105 | 0.01365 |
m | 1.4 | 0.1 | 0.095 | 0.0133 |
m | 1.5 | 0.1 | 0.085 | 0.01275 |
m | 1.6 | 0.1 | 0.08 | 0.0128 |
m | 1.7 | 0.1 | 0.075 | 0.01275 |
For PE, NE, TD which all have 0.03m3 allowed I enter:
Units | L | W | H | Calc m3 |
m | 0.31 | 0.31 | 0.31 | 0.029791 |
m | 0.6 | 0.2 | 0.24 | 0.0288 |
m | 0.75 | 0.2 | 0.19 | 0.0285 |
m | 1 | 0.2 | 0.145 | 0.029 |
m | 1.1 | 0.2 | 0.13 | 0.0286 |
m | 1.2 | 0.2 | 0.12 | 0.0288 |
m | 1.3 | 0.2 | 0.11 | 0.0286 |
m | 1.4 | 0.2 | 0.1 | 0.028 |
m | 1.5 | 0.2 | 0.095 | 0.0285 |
m | 1.6 | 0.2 | 0.09 | 0.0288 |
m | 1.7 | 0.2 | 0.085 | 0.0289 |
The calculated m3 I keep under the allowance to allow for packaging. As the length gets longer I specify dimensions to reduce the calcualted m3 on the assumption longer packages require more protective packaging
Woocommerce making the changes
With Flat Rate Box Shipping plugin installed:
Woocommerce->Settings->Shipping->Flat Rate (Legacy):
- Disable & confirm
Woocommerce->Settings->Shipping->Shipping Options:
- Calculations:
- Unselect ‘Enable the shipping calculator’
Woocommerce->Settings->Shipping->Shipping Zones = NZ
Note; All costs are entered GST exclusive in this store.
- Add a method per shipping option we wish to present to the customer:
- So one for each of our 1-6 options above, named accordingly.
- Within these methods:
- 1. North Island Urban
- 2. North Island Rural
- 3. South Island Urban
- 4. South Island Rural
- add rows in this order:
- Add a row for each of the 3 Express Packs, with smallest first + costs
- Add a row for each of the SG ticket dimension variation per table above + costs
- Costs for 1 & 3 are the same
- Costs for 2 & 4 are costs per 1 & 3 + RZ Rural ticket cost
- Within these methods:
- 1. North Island Urban
- 2. North Island Rural
- add rows for:
- PE ticket dimension variations per table above + costs
- Cost for 2 is per 1 + RZ Rural ticket cost
- Within these methods:
- 3. South Island Urban
- 4. South Island Rural
- add rows for:
- NE ticket dimension variations + costs
- Cost for 4 is per 3 + RZ Rural ticket cost
- Within these methods:
- 5. South Island Urban
- 6. South Island Rural
- add rows for:
- TD ticket dimension variations + costs
- Cost for 6 is per 5 + RZ Rural ticket cost
Initial purchase:
Not sure about holding NE tickets so we will wait for someone to order using one..
Poste haste buy 20170323 | |||
Code | Qty | Per unit | Gross |
LTR | 20 | 3.25 | 65 |
SML | 20 | 3.84 | 76.8 |
PD | 20 | 5.42 | 108.4 |
SG | 50 | 6.38 | 319 |
PE | 20 | 9.97 | 199.4 |
NE | |||
TD | 20 | 14.57 | 291.4 |
RZ | 10 | 4.4 | 44 |
1104 | |||
Not NE for now as is another $300 |
Purchase revised as forgot RUC charge:
FAF | RUC | |||||
3.50% | 3.10% | Tot | ||||
LTR | 3.25 | 0.11375 | 0.10075 | 3.4645 | 20 | 69.29 |
SML | 3.84 | 0.1344 | 0.11904 | 4.09344 | 20 | 81.8688 |
PD | 5.42 | 0.1897 | 0.16802 | 5.77772 | 20 | 115.5544 |
SG | 6.38 | 0.2233 | 0.19778 | 6.80108 | 50 | 340.054 |
PE | 9.97 | 0.34895 | 0.30907 | 10.62802 | 20 | 212.5604 |
TD | 14.57 | 0.50995 | 0.45167 | 15.53162 | 20 | 310.6324 |
RZ | 4.4 | 0.154 | 0.1364 | 4.6904 | 10 | 46.904 |
1176.864 | ||||||
1353.39 |
xxx