Cryptex puzzle box: design and print your own code lock
What the cryptex puzzle box is
A cryptex is a cylinder made of rotating dials that opens only when every dial shows the right character. This generator builds a cryptex puzzle box with a hollow compartment inside, large enough for a small gift, a ring, a rolled-up note or a gift card. You choose the code, the symbols on the dials and the size, and you print four plates that you assemble by hand.
With the default settings you get four number dials, the code 2580 and a compartment 47 mm across and 80 mm deep. The closed cryptex is about 110 mm long and 80 mm across. Letters work just as well: the letter cryptex with the code LOVE uses the whole alphabet on every dial, and the gift card cryptex has five dials with twelve letters each. All of them are in the example gallery.
The mechanism is not a plain stack of rings. It is the “anti-cheat” design by spool2kool: the usual trick of pulling on the lid and turning one dial after another until the cryptex gives way does not work here.
How the mechanism works
The cryptex has four kinds of parts:
- Compartment: the base with a tower. The tower holds your things, has a vertical key slot and a few ring grooves, and the base carries a notch that marks the code row.
- Spring sleeve: a tube that slides over the tower. It has a key that runs in the key slot, a flare at the lid end, lugs for the lid and one spring tongue per face and dial, each with a small bump.
- Dials: the rings you turn. They ride on the outside of the sleeve. Inside, every dial has a notch behind each face except the code face.
- Lid: it is glued onto the lugs of the sleeve and closes the cryptex.
Here is how they work together. The spring tongues ride on the inner wall of the dials. In every dial, exactly one tongue meets the wall behind the code face, where there is no notch, and is pushed inward. Its bump then drops into a ring groove in the tower and locks the sleeve. Only when every dial shows its code character over the key slot does that bump sit in the slot instead, and the sleeve with the dials and the lid slides off the tower.
Because one tongue locks in every wrong position, pulling feels the same in each of them. You cannot feel which dial is already correct. That is what the anti-cheat in the name means.
How the generator works
The generator runs entirely in your browser: nothing is uploaded, and the whole design lives in the share link. Open the Cryptex generator, type your code and symbols, and watch the closed cryptex in the preview. Then switch “Part” to each plate in turn and download it as STL or 3MF.
The preview lies on its side and leaves out the hidden spring sleeve, so it renders quickly. It shows what the finished cryptex looks like from outside. The exploded view of the original is not included.
Which plates to print
“Part” has five choices. Print only the four plates; “Preview (closed)” is a picture, not a print file.
| Part | Orientation | Weight | Time | Supports |
|---|---|---|---|---|
| Compartment | upright | 55.8 g | 2 h 26 min | no |
| Spring sleeve | upright | 33.1 g | 2 h 47 min | off |
| Lid | outside face down | 27.0 g | 55 min | no |
| Dials | upside down, all on one plate | 85.2 g | 3 h 54 min | no |
| Total | about 201 g | about 10 h |
The numbers are for the default cryptex (code 2580, ten faces, 20 mm face width), sliced in PrusaSlicer for a Prusa MINI with the 0.20 mm SPEED profile and Prusament PLA. Larger or smaller cryptexes need more or less. Every plate comes already turned the right way up, so do not rotate it in your slicer. You can look at each one as an example: compartment, spring sleeve, lid and dials.
The sleeve prints with supports off
Switch supports off for the spring sleeve. The slots around the spring tongues are shaped with steep roofs so that they bridge by themselves. If you turn on PrusaSlicer’s auto-supports anyway, it finds only three single-layer specks (0.01 g in total) at the base of the slot roofs. That is nothing a support structure could improve; it would only clog the slots.
Not test-printed by us
We have not printed and assembled this cryptex ourselves. What we did: the shapes match the OpenSCAD original to within about 1 % in volume, and every plate slices cleanly. Print one dial and the sleeve first and check the fit before you commit to the whole set.
Designing your cryptex
Part and dial
“Part” chooses the preview or one plate. With “Dials” selected, “Dial” 0 puts every dial that fits on one plate. Values 1 to 10 show a single dial; dial 1 is the one next to the base. If not all dials fit within 180 mm, the page tells you so and you print the rest one by one.
Code and symbols
“Code” is the opening code, one dial per character, 3 to 10 characters. Fewer than three characters are filled up to three dials; more dials than fit within 180 mm are shortened. “Symbols” lists the characters around each dial, in order. “Font” sets the lettering.
If the symbols have fewer characters than the faces, some faces stay blank. If there are more symbols than faces, each dial shows a run of them that contains its code character, so the letters do not give the code away. A code character that is missing from the symbols is added to its dial.
Dials
- “Faces per dial” (6–26, default 10) is how many characters each dial carries. More faces make the whole cryptex wider.
- “Face width” (10–20 mm, default 20) is the width of one face on the inner sleeve. Together with the faces it sets the diameter, and all mechanism sizes scale with it.
- “Dial height” (10–20 mm, default 20) is the height of one dial. The compartment gets this much depth per dial.
- “Character depth” (0.2–0.5 mm, default 0.5) is how deep the characters are engraved. On thin dial walls the generator makes it shallower and tells you so.
Fit and springs
- “Tolerance” (0–0.5 mm, default 0.2) is the play between moving parts.
- “Spring gap” (0.2–1 mm, default 0.5) is the width of the slot around each spring tongue.
- “Spring thickness” (0.5–1 mm, default 0.8) is the wall of the tongues; 0.8 mm suits a 0.4 mm nozzle.
- “Layer height” (0.04–0.4 mm, default 0.2): set the layer height you print with. The slit under each spring tongue is exactly one layer tall.
Colors
Two colors are available: “Body” for compartment, spring sleeve and lid, and “Dials” for the dials. Each plate prints in a single color, so you can switch filament between plates. A two-tone cryptex with a dark body and light dials reads well.
Sizes and codes
The inside of the compartment follows from the number of dials and faces. These are the sizes of a few examples:
| Example | Code | Dials × faces | Combinations | Compartment inside |
|---|---|---|---|---|
| Number cryptex | 2580 | 4 × 10 | 10,000 | Ø 47.3 × 80 mm |
| Letter cryptex | LOVE | 4 × 26 | 456,976 | Ø 88.5 × 56 mm |
| Gift card cryptex | MERRY | 5 × 12 | 248,832 | Ø 60.0 × 90 mm |
| Hex cryptex | C0DE | 4 × 16 | 65,536 | Ø 50.3 × 56 mm |
| Mini cryptex | 357 | 3 × 8 | 512 | Ø 19.8 × 36 mm |
For a hard-to-guess code, add dials and faces. Four dials with ten digits already give 10,000 combinations; six dials give a million. A roomier compartment needs more faces or wider faces. For a small cryptex use fewer faces and a narrower face width, as the mini cryptex does with 12 mm.
Assembly
These steps follow the notes of the original author; we have not assembled the model.
- Remove any stringing from the slots of the spring sleeve and check that the tongues move.
- Slide the dials onto the sleeve from its open end, starting with the last dial (the one next to the lid). The flare at the lid end stops it; dial 1 goes on last.
- Turn the dials so that the code characters line up with the key, the bump on the inside at the lower end of the sleeve.
- Slide the sleeve over the tower with the key in the key slot. The notch in the base marks the code row.
- Glue the lid onto the lugs of the sleeve. Keep glue away from the dials.
To change the code later, you cannot simply turn the dials: the notches are part of the print. Generate a new set of dials instead.
Printing tips
- Layer height: keep “Layer height” the same as in your slicer. The thin slit under each spring tongue depends on it.
- Nozzle: a 0.4 mm nozzle works with the default 0.8 mm spring thickness, which is two perimeters. With a different nozzle, pick a spring thickness that is a multiple of your line width.
- Material: PLA is what the numbers above use. Dials that stick usually need a little more “Tolerance”.
- Bed size: the default dials plate needs about 169 × 173 mm. Print dials one by one on smaller beds.
- Cleaning: remove strings and ridges from the bores, the tower and the slots before assembly so that everything slides.
What we changed compared to the original
The original needs supports for the compartment. This version adds 60° roofs over the tower grooves, over the notches in the dials and over the engraved characters, makes the slot tips above the tongues steeper and lets the top slot run straight through the flare. The lugs and lid pockets are turned half a step, and the dials get a steeper chamfer on the bed side. Instead of one long character string you enter a code and a symbol set. The bumps use 12 facets instead of 60 to keep the model light.
Origin and license
The geometry is a port of Customizable cryptex with anti-cheat mechanism by spool2kool, published on Printables under CC0 1.0, a public-domain dedication. The same author first published the model on Thingiverse in 2018 (thing 3236222). We ported the compartment, spring sleeve, lid and dials with their mechanism, and the changes above are ours. The fonts and further credits are on the licenses page.
Ready to start? Open the Cryptex generator, browse the examples, or try the maze gift box or the burr puzzle generator for more puzzles.
All parameters
The numeric settings of the generator with their default values and allowed ranges. Text, fonts, patterns and colors are set directly in the generator.
| Parameter | Default | Range | Meaning |
|---|---|---|---|
| Part | |||
| Dial | 0 | 0 – 10 | 0 puts every dial that fits on one plate; 1 to 10 shows only that dial (dial 1 sits next to the base). |
| Code and symbols | |||
| Dials | |||
| Faces per dial | 10 | 6 – 26 | How many characters each dial carries. More faces make the dials wider. |
| Face width | 20 mm | 10 – 20 mm | Width of one face on the inner sleeve. Together with the faces it sets the diameter; all mechanism sizes scale with it. |
| Dial height | 20 mm | 10 – 20 mm | Height of one dial along the cryptex. The compartment gets this much depth per dial. |
| Character depth | 0.5 mm | 0.2 – 0.5 mm | How deep the characters are engraved into the dial faces. |
| Fit and springs | |||
| Tolerance | 0.2 mm | 0 – 0.5 mm | Play between the moving parts. Raise it if the dials turn stiffly, lower it if they wobble. |
| Spring gap | 0.5 mm | 0.2 – 1 mm | Slot width around each spring tongue of the inner sleeve. |
| Spring thickness | 0.8 mm | 0.5 – 1 mm | Wall thickness of the spring tongues. Thinner tongues flex more easily but print less reliably; 0.8 mm suits a 0.4 mm nozzle. |
| Layer height | 0.2 mm | 0.04 – 0.4 mm | The layer height you print with: the slit under each spring tongue is one layer tall. |
Frequently asked questions
Which parts do I print?
Print four plates: compartment, spring sleeve, lid and dials (choose them under “Part”). The “Preview (closed)” is only a picture of the assembled cryptex and is not meant for printing. The default set weighs about 201 g and takes about 10 hours on a Prusa MINI.
Do I need supports?
No. Compartment, lid and dials print without any. Print the spring sleeve with supports switched off as well; PrusaSlicer’s auto-supports only flag three single-layer specks (0.01 g) there, which you can ignore.
Has this cryptex been test-printed?
Not by us. The design is a port of a popular CC0 model, adapted so it prints without supports, and its shapes match the OpenSCAD original to about 1 % in volume. The weights and times come from a slice, not from a finished print.
The dials turn stiffly or wobble. What can I change?
Change “Tolerance”. Raise it from 0.2 mm if the dials stick, lower it if they wobble. Print a single dial first (“Part”: Dials, then “Dial” 1) and slide it over the sleeve to test the fit.
Will the dials plate fit on my printer?
The default dials plate measures about 169 × 173 mm, so it needs a 180 mm bed such as the Prusa MINI. On a smaller bed, set “Dial” to 1, 2, 3 and so on and print the dials one by one.
Is my code stored anywhere?
No, the generator runs in your browser and uploads nothing. But the code is part of the share link and is visible in the dials’ notches, so anyone who has the link or the files can read it.
Origin & license
- Customizable cryptex with anti-cheat mechanism by spool2kool · CC0 1.0 · code ported – compartment, spring sleeve with spring tongues and bumps, lid and dials with notches and the anti-cheat mechanism ported and adapted for printing without supports (60° roofs over the tower grooves, the dial notches and the engraved characters, steeper slot tips above the spring tongues, the top slot straight through the flare, lugs and lid pockets turned half a step, steeper bed-side chamfer on the dials); code and symbol set instead of one long character string; preview lying down without the hidden spring sleeve