Most small e-commerce brands ship 80% of their orders in 3 to 5 corrugated box sizes chosen by gut feel. When carrier rates shift—especially USPS Commercial Cubic tiers and UPS/FedEx DIM-139 dimensional weight—even a 1-inch oversized carton can silently bump hundreds of orders into a more expensive pricing tier.
While building BoxAudit and our free USPS Ground Advantage Cubic Calculator, we designed a deterministic 3D cartonization pipeline that audits 90 days of historical Shopify, Etsy, ShipStation, or Pirate Ship orders directly against carrier rate tables.
1. Why USPS Cubic Math Breaks Intuition
USPS Commercial Cubic prices parcels by cubic feet ((L × W × H) / 1728, rounded down to the nearest 0.25 inch per dimension before multiplying) across 5 tiers (0.1, 0.2, 0.3, 0.4, 0.5 cu ft), as long as the longest side is <= 18" and actual weight is <= 20 lb.
A box measuring 10 × 7 × 5 in is 0.2025 cu ft, which crosses the 0.20 cliff and bills at the 0.30 tier. Trimming just half an inch off one side drops it under 0.20 cu ft and saves money on every single shipment—often $1–$3 per order.
2. Deterministic 3D Orthogonal Bin-Packing vs Heuristics
For multi-SKU orders, naïve volume summation (sum(L*W*H)) fails because rigid items cannot be melted to fill corners. Instead, we run an exact/deterministic 3D orthogonal packing pass:
- 6-orientation rotation search per SKU with deterministic tie-breaking so repeated runs always produce identical box assignments.
- Extreme-point candidate placement with axis-aligned bounding-box (AABB) overlap rejection.
- Dual-rate comparison per candidate box: compute both actual weight vs
DIM-139(ceil(L*W*H / 139)) and USPS Commercial Cubic tier, then pick the minimum total cost across the entire 90-day order set.
3. Stripping Buyer PII Locally Before Upload
Order exports from Shopify and ShipStation contain customer names, street addresses, and emails. An audit only needs SKU quantities, dimensions, destination ZIP/zone, and historical postage—never buyer identity. Stripping PII client-side in the browser before running the solver keeps merchant data clean by construction.
You can test single-box cubic tier cliffs with our free USPS Cubic Calculator or DIM-139 Calculator, or inspect the full 90-day order audit at getboxaudit.com.

