3D bin packing

3D Bin Packing Calculator

Enter a box size and the space inside your bin. Get a free carton count, layer layout and volume estimate, then use the full 3D planner below for mixed sizes and handling rules.

Complete basic estimates are free. Preview mixed loads in 3D; full custom plans unlock with a $9 pack.

Free carton fit calculator

One carton size, one empty rectangular space. Enter the inside dimensions and get a calculated carton count, layer drawing and volume use immediately.

Complete basic results. No account or card needed.

Size your load

1. One carton
2. Internal loading space

Presets change only the inside dimensions. Enter the usable space in your actual equipment; allow separately for doors, obstructions and loading clearance.

3. Payload and order

Leave payload blank for a space-only estimate. If entered, use the cargo allowance available for this shipment, after other cargo and applicable vehicle limits. Container tare is not cargo payload.

Estimated cartons in one space

36

12 cartons per layer × 3 layers = 36 cartons

Space estimate: payload has not been checked. Add your available cargo allowance to apply a weight limit.

Cartons per complete layer
12
Layers used
3
Volume use
100%
Carton volume
0.072 m³
Cargo weight
36 kg
Loaded height
30 cm
123456789101112
First layer: 12 cartons on an internal floor 60 × 40 cm.

The original carton height is vertical (10 cm). Amber cartons turn 90° on the floor. Higher layers repeat this orientation and pattern; a payload-limited final layer can be incomplete.

Loads for your order — feasible geometric estimate

1

Loading spaces needed for 36 cartons: 1. The drawing and cargo measurements above show one space at capacity, not the whole order.

Volume/payload lower bound: 1. This is only a necessary bound; it is not a demonstrated packing plan or a promise of the minimum number of loads.

Bookmark or share this result

The 60 × 40 × 30 cm bin is an illustrative internal space, not a named product specification.

How the carton estimate works

  1. Find a layer that fits. Compare both horizontal rotations and mixed layouts with a single dividing line. With all orientations allowed, repeat this check for each choice of vertical carton dimension.
  2. Repeat the layer within the height. Divide internal height by carton height in the selected orientation and round down. The method keeps one vertical orientation and repeats the same layer; it does not prove the best possible 3D packing.
  3. Apply payload and count the loads. If a payload is entered, divide it by carton weight and round down. Use the smaller of the space count and weight count. Divide the order by this capacity and round up for a repeatable geometric estimate.

What the estimate leaves to check

This is one rectangular carton size in an empty rectangular interior. It does not check door entry, wheel arches, packing gaps, pallets, carton crush strength, stacking stability, load restraint, unloading order or axle loads. Interior fit alone does not establish a practical loading plan. Check the actual shipment and equipment before loading.

Read the loading-order guide

Different cartons or handling rules?

The separate 3D planner handles mixed loads and additional constraints. Explore examples and preview your own load free; full custom 3D results start with a $9 pack.

Plan a mixed load in 3D

Use different item sizes and stacking rules in the full planner. Explore complete examples and preview your own cargo free; full custom plans unlock with a $9 pack. Rotate the result to inspect the arrangement and anything that did not fit.

The planner starts with example items. Calculate your own load to get a result for your shipment. Open the full planner

What 3D bin packing actually is

Three-dimensional bin packing is the problem of placing a set of rectangular items inside one or more containers so that nothing overlaps, nothing protrudes through a wall, and as few containers as possible are used. It sounds like arithmetic and it is not. Volume is necessary but nowhere near sufficient: a load whose boxes total 28 m³ will not go into a 33 m³ container unless the shapes happen to agree, and whether they agree depends on the order the boxes go in and on how each one is turned.

The problem is NP-hard, which has a precise and slightly deflating meaning: nobody knows a method that finds the provably best arrangement for a real load in reasonable time, and most people who study it expect nobody will. What is achievable is very good arrangements found quickly. For a container of freight, the gap between a good arrangement and the theoretical optimum is usually a point or two of utilisation; the gap between a good arrangement and stacking by eye is routinely ten or fifteen.

That second gap is where the money is. A 40 ft container costs the same to ship whether it leaves 78 per cent full or 91 per cent full, so every point of utilisation is a point off the freight bill for exactly the same cargo. The same holds one scale down, where an order shipped in a box one size too large pays dimensional weight on air.

The six orientations

A rectangular box can sit axis-aligned in a container six ways. A packer that only tries one is leaving space on the floor.

Orientation Footprint Height
L × W × H L × W H
L × H × W L × H W
W × L × H W × L H
W × H × L W × H L
H × L × W H × L W
H × W × L H × W L

Six per box compounds quickly: thirty boxes present 6³⁰ orientation combinations before you have even chosen an order to load them in, which is why a good arrangement is searched for rather than enumerated. In practice not every box gets all six. A pallet marked “this way up” has two, a drum has one, and the planner treats that as a hard constraint rather than a hint it is free to ignore when space runs short.

A worked example

Compare three uniform grids for identical boxes inside a 60 × 40 × 30 cm space.

Use a clear internal space of 60 × 40 × 30 cm and boxes measuring 20 × 10 × 10 cm. Allow rotation and compare axis-aligned layouts with no gaps.

Arrangement Orientation (L × W × H) Boxes fitted Packed volume
Flat, lengthwise 20 × 10 × 10 cm 36 0.072 m³
Flat, turned 90° 10 × 20 × 10 cm 36 0.072 m³
Standing tall 10 × 10 × 20 cm 24 0.048 m³

The first grid fits 60 ÷ 20 = 3 boxes along the length, 40 ÷ 10 = 4 across and 30 ÷ 10 = 3 layers: 3 × 4 × 3 = 36. Turn the footprint 90° and 6 × 2 × 3 also gives 36. Stand every box 20 cm high and only one full layer fits: 6 × 4 × 1 = 24, with 10 cm unused above. Each box occupies 2,000 cm³; 36 occupy 72,000 cm³, exactly the example space.

  • 36 boxes fill the ideal internal volume exactly; no additional box can fit without overlap or exceeding the boundary.
  • The 24-box count describes the shown tall grid. Mixing orientations could use its remaining headroom.
  • These layouts assume zero clearance and full face-to-face support. Weight, box strength and access for loading are not modelled.

The constraints that matter more than volume

Utilisation is the number everyone quotes, and it is rarely the number that decides whether a plan is usable. These four decide it.

What can bear weight

A plan that fills the container and crushes the bottom tier has not solved anything. Marking an item do-not-stack is free; on Business, each item can also carry a maximum stack height or a weight ceiling for whatever rests on it. The solver treats all of them as hard limits rather than preferences — it will open another container before it will put six tiers on something rated for two.

How stacking limits work

Where the weight ends up

A load can fit perfectly and still be dangerous. Concentrate the heavy items at one end and the container is over its axle limit on the road even though it is legal by total weight. The centre of gravity is tracked as the plan builds, so you see the imbalance on screen rather than at the weighbridge.

Centre of gravity, tracked live

The order it comes out

A multi-drop load has to be unloaded in reverse. The densest possible arrangement is worthless if the third customer's pallets are behind the first customer's, so items carry a priority that constrains where in the sequence they can be placed — a deliberate trade of a little space for a load the driver can actually work.

Priority and unloading order

When you know better

Some constraints never make it into a spreadsheet: the forklift at that depot, the door that opens the wrong way, the customer who wants their pallet visible. Any box in a finished plan can be dragged where you want it, and everything else re-solves around the position you pinned.

Placing items by hand

Which container to use at all

Choosing the box is half the problem, and it is the half usually decided by habit. Give the planner several container types at once — a 20 ft against two 40 ft high cubes, or three candidate carton sizes — and it reports what each option actually costs you in space rather than assuming the one you always order.

Packing across container types

How tightly to pack

The densest arrangement is not always the one you want. Interlocking every layer wins a few points of utilisation and can produce a load nobody can unload without dismantling half of it, so density is something you ask for deliberately rather than something applied by default.

Compact mode, and when to use it

How the solver works

Simulated annealing — and it is worth knowing why, because it explains what the tool will and will not promise you.

3DPACK.ING searches for arrangements using simulated annealing. It starts from a workable arrangement and repeatedly makes one small random change — swap two boxes in the loading order, rotate one, move a stack — then keeps or discards it. Early in the search it will accept changes that make the load slightly worse; as the search proceeds it grows steadily less willing to. The name is borrowed from metallurgy, where cooling a metal slowly lets its crystal structure settle somewhere lower-energy than quenching it ever would.

Accepting a worse arrangement sounds perverse, and the alternative is worse. A search that only ever improves walks into the first local optimum it meets and stops — typically a tidy-looking load with one awkward void it cannot undo, because undoing it means going backwards first. Tolerating a temporary loss is precisely what lets the search climb out of that void and find the arrangement on the far side of it.

There is no claim of optimality here, and there should not be. The solver returns the best arrangement it found in the time it was given, and running it twice on the same load can return two different plans of near-identical quality. What it does guarantee is feasibility: every plan it returns physically holds. Nothing intersects, nothing floats, nothing exceeds the payload, and nothing sits on a box you said could not bear it.

Call the same solver from your own code

Container reference

Interior dimensions, not exterior — the numbers that decide what fits.

Container Interior (metric) Interior (imperial) Capacity Max payload
20 ft standard 5.90 × 2.35 × 2.39 m 19'4" × 7'8" × 7'10" 33.2 m³ / 1,172 ft³ 28,200 kg / 62,170 lb
40 ft standard 12.03 × 2.35 × 2.39 m 39'5" × 7'8" × 7'10" 67.7 m³ / 2,390 ft³ 26,700 kg / 58,865 lb
40 ft high cube 12.03 × 2.35 × 2.69 m 39'5" × 7'8" × 8'10" 76.3 m³ / 2,694 ft³ 26,460 kg / 58,335 lb
45 ft high cube 13.56 × 2.35 × 2.69 m 44'6" × 7'8" × 8'10" 86.1 m³ / 3,040 ft³ 25,600 kg / 56,440 lb
20 ft reefer 5.44 × 2.29 × 2.27 m 17'10" × 7'6" × 7'5" 28.3 m³ / 999 ft³ 27,400 kg / 60,410 lb

Nominal figures. Real interiors vary by builder, by age and by whether the floor has been replaced, and payload is limited further by road weight rules at both ends of the journey. Confirm against the container you have actually been allocated before planning to the centimetre.

Questions

Is the 3D bin packing calculator free?

Yes. Explore complete examples and preview a custom load with up to ten box types and five hundred pieces without an account. New accounts get ten previews a month. Unlock the full custom result with a $9 pack, with no subscription. Existing accounts and purchases retain their previous access.

Do I have to sign up to try it?

No. One calculation runs without an account, so you can see a real plan for your own boxes before deciding whether the tool is worth an email address.

What is the difference between 2D and 3D bin packing?

Two-dimensional packing arranges shapes on a surface — nesting parts on a steel sheet, or laying pallets out on a trailer floor. Three-dimensional packing stacks them as well, and stacking is what introduces the constraints that make the problem hard: what can bear weight, what has to stay upright, and where the centre of gravity ends up once everything is in.

How many orientations does the calculator try?

All six for every box, unless you say otherwise. Marking an item “keep upright” reduces it to two, and that restriction is treated as a hard constraint — the solver will use another container before it will lay that item on its side.

Can it pack more than one container at a time?

Yes. You can preview multi-container packing and fill mode. The full custom answer, including container counts and fit assessment, requires paid access; a $9 pack includes these features while credits remain.

Does it account for weight, or only volume?

Both. Every item carries a weight, the plan respects the container's maximum payload, and the centre of gravity is tracked as the load builds — so an arrangement that fits but would tip is visible on screen rather than at the weighbridge.

Can I use it through an API?

Yes, on a paid plan. The same solver is reachable over a REST endpoint that accepts a plain-English description of the load; the API reference documents the request, the response and every failure it can return.

How big a load can it handle?

Up to five hundred boxes per load for previews, the $9 pack and Pro. Business has no fixed piece ceiling. Larger loads still take longer to solve.

Pack your first load

Type what you are shipping in plain English, or paste a list. No install, no card, and no account for the first one.

Ten previews a month with an account. Full custom results unlock with a $9 pack.