3D PrinterWiki

Box generator

A custom box with a lid that fits, sized by what has to go inside.

mm
mm
mm

The 3MF keeps the box and the lid as two parts.

More options
mm
mm
mm
mm
mm
mm

Sometimes the most useful print is the simplest: a box. A case for a circuit board, a container for screws, a gift box, a holder for SD cards or batteries, a drawer insert. Downloaded boxes are never quite the right size, and modelling one in CAD takes longer than printing it. This box generator makes a box with rounded corners and a lift-off lid from the inside dimensions you need, with walls, floor and lid clearance you can adjust, and downloads both parts ready to print.

Box generator showing a rounded box and its lid with a lip
A 60 × 40 × 30 mm box with a lift-off lid.

How to make a box

  1. Enter the inside width, depth and height: the space you need for what goes in. Add a millimetre or two of room if the contents should come out easily.
  2. Choose the lid: a lift-off lid with a lip, or no lid.
  3. Adjust the details under More options: wall and floor thickness, inside corner radius, lid clearance, lip height and lid thickness.
  4. Check the size line: it gives the outside dimensions, so you can see whether the box fits its place.
  5. Download the STL, or the 3MF to get the box and the lid as separate parts.
How to make a 3D printed box: enter the inside size, set walls and lid, download

Why the inside size

A box is defined by what has to fit in it, so the generator works from the inside. The walls are added around it, so the outside grows by twice the wall thickness, and the floor is added underneath. With the defaults, a 60 × 40 × 30 mm inside becomes 63.2 × 43.2 × 31.2 mm outside. The inside corner radius you set is kept inside; the outside corners are rounder by the wall thickness, so the wall stays the same thickness all the way round.

How the lid fits

The lid is a flat plate the size of the box's outside, with a lip on its underside that slips inside the box walls. The lip is made smaller than the box's inside by the Lid clearance on every side: 0.2 mm by default, so it slides in without force but doesn't rattle. Printers differ, so the right clearance depends on yours: 0.15 mm gives a snug fit on a well-tuned printer, 0.3 mm a loose one on a printer that over-extrudes. The lip is 4 mm high by default, enough to keep the lid in place; raise it for a lid that holds more firmly.

3D printed box settings: wall, floor, lid clearance, lip height, corner radius, orientation

Walls and floor

Thin walls save filament and time, but they need to be thick enough to print solidly. The best wall thickness is a multiple of your line width: with a 0.4 mm nozzle printing 0.4 to 0.45 mm lines, 1.6 mm gives four solid lines with no gap between them. The floor is 1.2 mm, six layers at 0.2 mm. For heavy contents, such as tools or many screws, use 2 to 2.4 mm walls and a 2 mm floor. Large, flat boxes may warp at the corners with ABS or ASA; PLA and PETG rarely do.

Printing the box

Print the box with its open side up and the lid with its lip up, the way they lie in the preview: neither needs supports. A 0.2 mm layer height is plenty. Use at least three walls in the slicer so the walls print solid. Watch for elephant's foot on the box's top rim and the lid's lip: a slightly squashed first layer on the lid can make it tight, which the slicer's elephant foot compensation or a little more clearance fixes.

Want to label the box? Make raised text with text to STL and place it on the lid in your slicer, or print a name with the keychain generator and glue it on.

Common boxes and their sizes

If something has to fit exactly, print a short test first and adjust the inside size by what you measure. Printed holes and insides usually come out a little smaller than designed, often by 0.1 to 0.3 mm.

Tips for getting a 3D printed box lid to fit: clearance, elephant's foot, test prints

Box generator questions

How do I make a box with a lid to 3D print?

Enter the inside size on this page, keep the lift-off lid, and download the STL. Print both parts open side up.

How much clearance does a printed lid need?

About 0.2 mm per side on most printers: 0.15 mm for a snug fit, 0.3 mm for a loose one.

How thick should the walls of a printed box be?

1.6 mm with a 0.4 mm nozzle for most boxes; 2 to 2.4 mm for heavy contents.

Can I make a box without a lid?

Yes. Choose No lid, and the generator makes just the box.

Why is my lid too tight?

The print came out slightly larger than designed. Raise the lid clearance by 0.05 to 0.1 mm and print the lid again.

How do I make the box bigger than my printer?

You can't print it in one piece. Make two smaller boxes, or cut the model in your slicer and glue the parts.

More 3D printing tools

Updated November 2026 · How these tools work