Simulating cardboard boxes that behave like cardboard

Robots learn in simulation, and most simulators treat a box as a solid block. We built boxes in MuJoCo that fold, dent, spring back and crush like real ones, and checked the numbers against lab measurements.

Amogh Shrivastava

Founding Engineer, Kite ML

Oct 3, 2026 · 19 min read

Robots that handle packages touch cardboard all day. They pick boxes off shelves, fold flaps shut, squeeze cartons into totes and pull parcels off conveyors with suction cups. Most of that skill is now learned rather than hand-programmed, and a lot of the learning happens in simulation.

The reason is cost. A robot learning by trial and error needs thousands or millions of attempts. Doing that on real hardware takes months, breaks things, and needs a person standing by. In a physics simulator the same attempts run in parallel, overnight, for the price of compute. The trained behavior (usually called a policy) is then moved onto the real robot.

That last step only works if the simulated world behaves like the real one. Wherever the two differ, the policy learns something that isn't true, and it fails on the real robot in ways that can be hard to trace. This gap is called the sim-to-real gap. Closing it is a large part of practical robot learning.

Cardboard boxes turn out to be one of the places where that gap is wide.

Why a box is hard to simulate

Most physics simulators, including MuJoCo, the one we use, are built around rigid bodies: objects that never change shape. A rigid box is just a cuboid with a mass. It can slide, tip and be grasped, but it can't bend.

A real cardboard box bends constantly:

  • The flaps fold. They fold along score lines, creases pressed into the board at the factory. A folded flap doesn't stay where you put it. It springs partway back, and how far depends on how far it was folded, how fast, how long it was held, and how many times it has been folded before.
  • The walls flex. Press a finger into the side of a shipping box and the wall dishes inward. Push hard enough and it keeps a dent. Squeeze an empty box with two hands and the walls bow.
  • The box can be crushed. Stack enough weight on it and the walls buckle and collapse. Each box has a rated load it can carry, and that rating halves in a humid warehouse.
  • The surface matters. Board slides differently on board than on a rubber gripper pad. A suction cup that holds firmly in the middle of a panel won't seal over a seam or a crease, and the board itself leaks air.

A robot closing a box, packing a carton or lifting a parcel depends on every one of these. If the simulator can't fold a flap realistically, a policy can't learn to close one. If walls never dent, it never learns how hard is too hard to squeeze.

The textbook answer to deformable objects is the finite element method, which splits the object into thousands of tiny pieces and solves for how each one stretches. It is accurate, and it is far too slow to train robots on. The usual alternative, a rigid block, is fast and wrong. We wanted something in between: fast enough to run inside a robot-learning loop, and accurate enough that its numbers match measurements on real boxes.

A 60 N poke (about the weight of 6 kg) on a corrugated shipping box. The wall dishes inward between its corners.
Two 60 N pushes squeezing the same empty box from both sides

The idea: a box is a mechanism

Unfold any box and you get a flat sheet called a blank: panels connected by creases. Folded up, it behaves much like a set of stiff plates joined by hinges. The panels are fairly stiff. Nearly all the interesting motion happens at the creases.

So instead of simulating cardboard as a continuous material, we simulate a box the way you'd describe it to someone: as stiff panels connected by hinges. Each hinge has a rule, a crease law, that says how much it resists folding and what it remembers. MuJoCo handles hinged bodies very well, so this runs quickly.

Two refinements make that simple picture behave like cardboard. First, a single flat panel per wall can't dent, so each wall is split into a grid of smaller patches joined by their own hinges, set to match the bending stiffness of real board. Second, each crease law comes from laboratory measurements of real creases, not from guesses.

The full model has eight layers. Each one makes a single decision, and each decision is backed by a source.

01

Board

Measured stiffness in each direction, strength, thickness, and mass per square metre.

02

Walls

A 6 x 3 lattice of patches, so a wall dents, bows and buckles both ways.

03

Joins

Glued corners, a rigid manufacturer's joint, full-width score lines, tape.

04

Creases

A measured law: peak, plateau, relaxation, springback and fold history.

05

Variability

Humidity per scene, manufacturing tolerances, fold speed, crease scatter.

06

Contact

Elliptic friction, measured coefficients, friction memory, suction.

07

Solver

The MuJoCo settings that changed results, pinned and explained.

08

Validation

Each layer checked against a published measurement.

The board

Shipping boxes are made of corrugated board: two flat paper sheets (liners) glued to a wavy sheet in between (the flutes). Flute sizes have letter names. C-flute, about 4 mm thick, is the common shipping box. B and E flute are thinner. Drawing every flute would be expensive and wouldn't change anything at the scale a robot cares about, so we treat the board as a solid plate of the same thickness, with the bending stiffness measured on real board in each direction. Corrugated board is about twice as stiff along the flutes as across them, and the model keeps that difference.

We also covered the thin paperboard used for cereal and cake boxes, and the rigid greyboard used for presentation boxes, using manufacturers' datasheets. A box's mass comes from its flattened area times the weight of its board per square metre. We checked that rule against the published weights of 23 real boxes.

The walls

Each wall is a 6 x 3 grid of patches. The horizontal hinges between rows bend with the board's stiffness along the flutes; the vertical hinges within each row bend with its stiffness across them. This lets a wall dish inward around a fingertip, bow under a squeeze, and buckle under a heavy load.

Corners turned out to matter more than we expected. In a real box, neighbouring walls meet at a continuous fold, so they can't separate. In our first version the walls were joined only along the bottom, and under load they peeled apart at the corners like an opening flower. Pinning every row of each wall to its neighbour fixed that. One corner is also stiffer than the rest, because that is where a real box is glued together at the factory (the manufacturer's joint).

A 5 N fingertip press on a cereal carton
A squeeze on a paperboard cake tray

The creases

The crease law decides how flaps behave, so this is where we spent the most effort. It is built from a series of careful measurements on creased paperboard strips by Nagasawa and colleagues (2011 to 2019), and it reproduces several effects you can feel with your hands:

  • A fresh crease is stiff at first, gives way suddenly near 20°, and then folds with steady resistance.
  • Let go, and it springs back a long way. A strip folded to 90° comes back to about 46°.
  • The fold you put in stays partly. The model tracks this permanent set for every crease, at every step of the simulation.
  • Folding faster takes more force and gives more springback. Robots fold much faster than lab machines, so this matters.
  • A crease that has been folded before is softer: about 12% less resistance the second time, levelling off after about five folds. Holding a flap down makes it relax, and once released it keeps creeping open for a while.
  • No two creases are identical. Each one gets a small random variation, matching the scatter seen across real boxes.

The chart below shows a simulated strip folded to 90°, held for a second and released, against the measured values.

Crease bench: fold, hold, release
simulated measured

A 38 mm creased paperboard strip, folded to 90° at 0.2 rev/s, held 1 s, then released. Moment per metre of crease against fold angle.

0.00.10.20.3
0°30°60°90°
fold angle
The numbers
PointMeasuredSimulated
First-fold peak, N·m/m0.2440.245
Moment at 90°, N·m/m0.2150.218
After a 1 s hold, N·m/m0.1750.170
Rest angle 1 s after release46.1°46.5°
The same carton flap folded fast and slow
A flap lifted and released. It springs back and settles.

Real boxes vary

No two boxes in a warehouse are the same, so the model doesn't treat them as identical either:

  • Humidity. Cardboard absorbs moisture from the air and gets weaker. The simulator sets one humidity for the whole scene, since boxes in the same room share the same air, and adjusts the stiffness and strength of every box to match. At 90% relative humidity a box carries about half the load it does in a dry room.
  • Manufacturing tolerances. Packaging standards allow boards to be slightly warped, panels slightly off size, and flaps slightly off square. We draw these from the allowed ranges. A box with those imperfections crushes at about 85% of the load a perfect one carries.
  • Flaps that close the way real ones do. On a real box, the long top flaps fold down over the short ones. The model stacks them in the same order.

Friction and suction

Friction values come from measurements made specifically for package-handling simulation: cardboard sliding on cardboard, and cardboard on the rubber pads robots use. Board-on-board friction can also remember which way it was last rubbed. Repeated sliding one way wears the surface fibres down, and sliding back the other way catches them, which raises friction by about 12%.

Suction cups follow simple physical rules. A cup only seals if its whole rim sits flat on one face, not across a seam, edge or crease. Its holding force is the vacuum times the cup area, reduced for the air that leaks through porous board. The pull acts on the actual panel, so a thin wall can bulge outward under the cup.

One cup can't hold a 3 kg box
Three cups lift it
A cup placed over the flap seam never seals

Where the numbers come from

Almost nothing in the model is a free parameter we picked to make a result look right. Before building anything, we went through about 250 sources:

  • Lab studies of board and creases. Papers that bend, fold, crush and slide real cardboard and report the numbers. The crease behavior comes mostly from Nagasawa and colleagues' series on creased paperboard. Board stiffness comes from Nordstrand (2003) and Popil (2012), and friction from Park and colleagues (2019), who measured it specifically for package-handling simulation.
  • Industry standards. These say how boxes are made and tested: the FEFCO style codes that define a regular shipping box, the PMMI B155 tolerances for how far a real box may deviate from its drawing, and the ASTM D642 compression test we copy in simulation.
  • Manufacturer datasheets and catalogs. Board grades, thicknesses and weights per square metre, and the listed weights of real boxes, which we used to check how the model computes mass.
  • Work on robots and boxes. Robot box-handling and sim-to-real papers, simulation tools, and public datasets, to see what others had tried and where their simulated boxes fell short.

We used these sources in three ways. Where a paper measured exactly the quantity we needed, the model uses that value directly. Where no direct measurement existed, we derived the value from ones that did and marked it as an estimate. Corrugated creases are an example: we scale the one published double-wall measurement down to single-wall board. A third group of studies we kept back on purpose and used only to check the finished model: the crush tests, the humidity data and the crease springback curves. Every value carries its source, and every estimate is flagged, so when a result disagrees with reality we know which inputs to suspect first.

Checking it against real measurements

A simulator can look right and still be wrong in ways that matter to a robot, so every behavior above was compared with a published measurement.

The most important check is crushing. The packaging industry's standard estimate of how much load a box can carry before it collapses is the McKee formula, which predicts it from the board's strength and the box's size. Across 409 tested boxes it is accurate to within about 6 to 11% (Urbanik & Frank, 2006), which makes it a demanding target. We crushed a standard 400 x 300 x 300 mm C-flute box between two flat plates in simulation, driving the top plate down at a steady rate the way the standard lab test does (ASTM D642), without tuning anything to the answer. It collapsed at 0.87 of the McKee prediction, inside the formula's own margin of error. There is a caveat to that result, which we come back to under what's still open.

Crush test on a C-flute box between two flat plates
The squeeze from earlier, at 90% humidity
A box with manufacturing imperfections carries 85% of the load

The full set of comparisons:

CheckMeasuredSimulated
Crease peak resistance, slow / fast fold0.244 / 0.258 N·m/m0.247 / 0.261
Crease resistance at 90°, after a 1 s hold0.215, 0.1750.218, 0.170
Angle where a fresh crease gives wayabout 20°18.3°
Rest angle 1 s after release, slow / fast46.1° / 42.9°46.5° / 43.3°
Rest angle 10 s after release41.2°42.0°
Second fold vs first0.87 to 0.900.89
C-flute box crush vs McKee1.00 ± 0.110.87
Crush strength at 90% humidity0.500.50
Grip needed to hold a box vs friction formula1.01.09 to 1.25
Friction rise when sliding is reversed+11 to 17%+12%
Force to fold a carton flap< 4.4 N0.2 to 1.7 N
B-flute box crush vs a measured box (2652 N)1.00.42 (open)

What tripped us up

Several of the results above only came out right after we found something wrong. These are worth sharing, because some of them will catch anyone simulating packages.

Boxes slid out of the robot's hands. Holding a box took nearly three times the grip force that basic friction says it should. Part of that was bookkeeping: the textbook formula leaves out the weight of the box itself, which for a large shipping box is about 0.4 kg. The bigger part was the simulator. MuJoCo's default friction model approximates friction with a few flat faces (a pyramidal cone), and under a steady load it let the box creep down between the fingers at about 4 mm per second. Switching to its more accurate elliptic friction model stopped the creep, and the grip needed then landed within 9 to 25% of the formula.

Some starting values were off by large factors. Bending stiffness for C-flute board had been calculated from an idealised liner and came out about half the measured value. Crease stiffness for small folds was about 6 times too soft compared with values used in validated engineering models. One friction value used for board-on-board was really the value for board-on-rubber. Each of these came to light only by comparing against measured data.

A resistance was applied in the wrong direction. Our first crease rule made a crease three times harder to move back toward flat. Measurements show the opposite: unfolding takes less force. What really is harder is bending a crease the wrong way, past flat.

A test rig was flattering us. In our crease test, the fixed half of the strip was rubbing against the moving half at the hinge, and that friction slowed the springback. Our crease law had been tuned to match that rigged result. With the rubbing removed it was clearly off, so we recalibrated it on the clean test.

Flaps were trimmed too short. To let flaps close without colliding, we had shortened them by 12 mm at each end. That quietly moved the load path when a box was stacked on, and crush strength dropped to 80% of McKee. Using the industry-standard 3.2 mm gap, and joining each flap along the full width of its wall the way a real crease runs, brought it back.

A sign was lost in the crease code. The crease rule was right, but the code that hands it to MuJoCo dropped a minus sign in one branch. On thin paperboard, such as a cereal carton, MuJoCo pushed back about 45% harder than the rule said during the first part of a fold. Our crease test couldn't see it, because it reads the rule's own output. We found it when flap forces in a full box didn't add up to what the rule predicted.

What we've added since

The results above are for the core model. Since then we've added several behaviors that matter once a robot starts handling boxes roughly. Each one is checked against a measurement or a physical sanity test, and each can be switched on or off, so the validated results above don't change unless a scene asks for it.

  • The surface crushes under a gripper. Press a pad into corrugated board hard enough and the flutes under it collapse, leaving a permanent shallow dent even when the wall itself doesn't bend. In the standard flat-crush test the simulated board gives way at 203 kPa, against 174 to 201 kPa measured. Near that limit it creeps and gives way after several seconds, which is why a robot that holds a box too long can damage it.
  • Tape and glue can let go. A taped flap holds until the tape's peel strength is exceeded, then peels open. The glued seam at the box's corner can unzip row by row.
  • The bottom can burst. The bottom flaps are real panels held by tape, so a box lifted with too heavy an item on the seam fails the way real boxes do: the tape peels and the item drops through. In our test a taped bottom held 20 kg and failed at 40 kg.
  • Contents can be loose. Cereal in a bag shifts and settles differently from a solid block. Under a hard sideways shove, bagged contents moved their centre of mass 21.5 mm, against 18.3 mm for a rigid block.
  • Creases can be off. Real creases are sometimes scored a few millimetres from where they should be. Moving the long flaps' creases 1.5 to 10 mm cuts crush strength by 7 to 39%, in line with the 26 to 40% losses measured on real boxes (Mrowczynski, 2021).
  • Walls can twist. Splitting every wall patch into two hinged triangles lets panels twist and fold along diagonals, so a box can crumple and rack instead of folding only along a grid.
Two gripper pads at 72 N slowly crush the board surface
A pulled flap peels its tape once the tape's limit is passed
The glued corner seam unzips under a pull
A 40 kg item on the bottom seam bursts the taped bottom
Bagged cereal shifting inside a carton
A thin-board box with twisting walls, racked under a top load

Some inputs to these are still estimates: the peel strength of tape on corrugated board, the strength of the glued seam, and the exact shape of the surface-crush curve.

What's still open

  • Thin board and thick board pull in different directions. Our standard model gets C-flute right but gives a thin B-flute box well under half its measured strength. Thin walls buckle early and keep carrying load through their corners, and our flat wall patches can't do that. Splitting every patch into two hinged triangles, so the panels can twist, fixes thin board: B-flute lands at 0.88 to 1.01 of the measured box, depending on how finely the walls are divided, and E-flute matches McKee. The same change makes C-flute 1.8 times too strong. A real thick wall must give way through something we don't model yet, and crushing along the score lines is the likely candidate. Until that's in, the twisting walls stay optional.
  • The C-flute match is partly luck. Corrugated board is stiffer along its flutes than across them, and we found that our standard wall model uses the two stiffnesses the wrong way round. With them corrected, the standard model's C-flute result drops to about 0.65 of McKee. So the good C-flute number above comes partly from two errors cancelling. The twisting-triangle walls use the correct directions. Fixing the thick-board failure mechanism is what will let us make them the default.
  • The corrugated crease law is an estimate. The only published measurement of a corrugated crease is for thicker double-wall board, which we scale down to single-wall board.

Fast models and detailed models

The detailed box above has 80 moving parts and needs very small time steps (a quarter of a millisecond), so it runs slower than robot training needs. We use it in tiers:

ModelPartsTime stepCapturesUsed for
Hinged panels + crease law122 msfolding, flaps, springback, graspingtraining
6 x 3 wall grid + crease law800.25 msdents, bulging, squeezing, crushingtesting and calibration
Finer grids130+0.1 msdiagonal folds, thin-board bucklingchecking the others

Policies train on the fast hinged model. The detailed model tells us where the limits are, such as how hard a wall can be pressed before it dents and how hard a box can be squeezed before it crushes. Those limits become penalties during training. A policy that stays under them on the fast model won't damage the box in the detailed one either.

To check that the fast model is actually useful for learning, we trained a policy to close a box flap with a single fingertip. Each episode drew a different box: a different weight, centre of mass, flap starting angle and crease springback. Fifty minutes of reinforcement learning on an ordinary laptop CPU was enough:

PolicyFlap closedWall dents or over-squeezes
Learned policy, 50 minutes of training86%0
Hand-written sweep to a fixed angle80%0
Doing nothing0%0

The hand-written sweep pushes every flap to the same angle, so it over-folds flaps that spring back less than average. The learned policy adjusts to how each flap responds. The fast model also runs on JAX for GPU-parallel training, and it matches the CPU version closely enough that the two give the same episode outcomes.

What's next

A box model is only useful for what it lets robots learn. These are the tasks we're building toward:

  • Closing and sealing boxes. Folding four flaps in the right order, holding them against their springback, tucking a lid and taping a seam. Today this is taught almost entirely with real-robot demonstrations. With creases that behave like real ones, much of it can be practiced in simulation first.
  • Packing. Putting items into boxes and boxes into totes, cages and pallets. A packing policy has to know how much a box can take before its walls give, how a half-full carton bulges, and how a stack of boxes shares load. That is what the crush and humidity results are for.
  • Picking anything a warehouse ships. Grasping and suction-picking boxes of every size, weight, wear level and dampness. That means knowing when a single suction cup will hold, when it needs three, and when a seam or a soft panel means it won't hold at all.
  • Opening and unpacking. Finding the seam, lifting flaps, getting the contents out without tearing the box.
  • Adapting to the box in front of the robot. Every real box is a little different. A robot should be able to touch a box once or twice, estimate its stiffness and crease strength, and adjust its grip and folding to match. The same model that runs in simulation can do that estimate.

Each of these needs the simulated box to fail in the same ways a real box fails, which is why we started with the cardboard and not with the robot.

Sources

The main studies and standards behind the numbers in this post:

  • Nagasawa, S. and colleagues: a series of measurements on creased paperboard, covering folding moment, springback, relaxation, fold speed and refolding (2011, 2015, 2016, 2019), and on corrugated creases with Komiyama (2012).
  • McKee, R. C., Gander, J. W. and Wachuta, J. R. (1963). Compression strength formula for corrugated boxes.
  • Urbanik, T. J. and Frank, B. (2006). Accuracy of the McKee formula across 409 single-wall boxes.
  • Fehér, Pidl and Böröcz (2023). Compression strength of corrugated boxes. Materials 16, 597.
  • Nordstrand, T. (2003). Bending and shear stiffness of corrugated board.
  • Popil, R. E. (2012). Bending stiffness of corrugated board. BioResources 7, 2553.
  • Baum, G. A., Brennan, D. C. and Habeger, C. C. (1981). Shear modulus of paper. Tappi 64.
  • Park and colleagues (2019). Friction of corrugated board for handling simulation.
  • Johansson and colleagues (1998), and Garoff (2004). Paper-on-paper friction and its direction memory.
  • Pradier and colleagues (2016). Scatter between creases on the same board.
  • Mrówczyński and colleagues (2021). Strength loss from creases scored off position.
  • ASTM D642: compression test for shipping containers. PMMI B155: carton tolerances. FEFCO code: box styles.

Similar articles