How ShipperHQ Packs Best-Fit Dimensional Shipping Boxes


This article describes how ShipperHQ packs products into boxes for Dimensional Shipping when the packing algorithm is set to Best-Fit packing. You can check the packing algorithm via Dimensional Rules > Settings > “Packing Algorithm”.

Packing Boxes

ShipperHQ first checks the individual dimensions of the products to ensure that the dimensions do not exceed the dimensions of the box. For example, a product that has dimensions of 5x3x12 cannot fit into a 10x10x10 box because one of the dimensions exceeds each of the dimensions of the box. The system does, however, attempt to rotate the product so that same product could fit into a 14x10x10 box, for example.

Next, the system takes the volume of the product(s) in the cart and compares that against each of the boxes that are eligible to be used for that product. So, for example, a 5x5x5 product has a volume of 125 so it can fit into any box that has a volume greater than 125 (after accounting for the individual dimensions, above). This denotes how many of that product can fit into each box and how much space is left over.

Lastly, the system checks to maximum weight and the maximum quantity for the boxes. This is defined in Box Definitions > (box name) > “Max Quantity Box can Hold” and “Max Weight Box can Hold”.

Note that the box tolerance/padding will have an effect on the volume of the products that can fit into a box.

If you are using Magento/Zoey you can also apply master packing boxes, which will be favoured over other packing boxes.


When attempting to pack, items for which no possible boxes are found will go into a single fallback box which will adopt the dimensions of the largest item that goes into it. This box will be called SHQ CUSTOM. The box will be the dimensions of the largest product with no box available and all boxless items will go into it for rating purposes, even if they logistically wouldn’t fit. There are some cases where this is desirable (such as taking the total weight of the cart and rating it as a single item with no dimensions to overcome package limits for an LTL carrier) but in general you will want to define enough boxes so that this SHQ CUSTOM box will not be used.

Further Reading

It is also possible to modify the products to pack specific quantities of products into boxes, as detailed in this article.

If you have a single product that ships in multiple products please see this article. This can be used if, for example, you have a table product where the table top ships in one box with its own dimensions and the legs ship in one or more boxes of a different size.