
Newsletter Subscribe
Enter your email address below and subscribe to our newsletter

Enter your email address below and subscribe to our newsletter
Turn a list of object heights into a workable set of shelf levels inside a cabinet.
Turn a list of object heights into a workable set of shelf levels inside a cabinet.
Heights of up to four object groups, tallest first is handled automatically.
Everything runs in your browser. No data is uploaded.
A cabinet interior is a fixed height, and the objects to be stored have their own heights. Turning the two into a workable set of shelves is a cumulative arithmetic problem: each shelf needs a bay tall enough for the object plus a little clearance, and every shelf itself consumes thickness. This planner takes the cabinet interior height, a set of object heights, the shelf thickness and a per-bay vertical clearance, then works out how many bays fit and where each shelf level sits.
The calculation runs tallest object first. For each object, a bay height is formed by adding the clearance to the object height. A shelf of the given thickness is added below that bay, and the running total of bay heights plus shelf thicknesses is compared with the cabinet interior height. The bay is kept only while that running total stays within the cabinet; as soon as adding the next bay would exceed the interior height, the process stops. The leftover is the cabinet height minus the used height, and the shelf levels are the cumulative sums of each bay height plus one shelf thickness.
The tool reports the bay heights, the used height, the leftover and the list of shelf levels measured up from the cabinet floor. Everything runs locally in the browser: no measurements are transmitted or stored, and every result can be reproduced by hand with the formulae published below. It describes vertical geometry only; it does not decide shelf depth, shelf material, cabinet width or the finish of any surface.
Every height, clearance and thickness on this page is a commonly used planning convention, not a regulatory requirement or a mandatory standard. The figures are a starting arrangement to check against real object heights and a real cabinet, rather than a finished cutting list.
Fixed, evenly spaced shelves are simple to plan but rarely match the objects actually stored. A cabinet with every bay the same height wastes space above short items and may still be too tight for the tallest one. Sizing each bay to a specific object, with a small clearance on top, recovers that wasted space and makes the tallest object the starting constraint rather than an afterthought.
Clearance is the second reason the arithmetic matters. A bay that exactly equals the object height leaves no room to lift the object in or out, so a per-bay clearance is added; 2 in is the commonly used planning figure here. Because the clearance is added to every bay, a cabinet with four bays gains four times the clearance in total, and a small change to that figure can decide whether a fourth bay fits at all.
Ordering the objects tallest first is a deliberate simplification. Placing the tallest bay at the bottom of the running sequence means the largest single demand is tested while the cabinet is still empty, and the remaining smaller bays are added against whatever height is left. It gives a determinate answer from a fixed set of inputs rather than requiring a choice among many possible arrangements, which is useful when the goal is a repeatable plan rather than an optimised one.
Shelf thickness is easy to overlook because it is small, but it is charged once per bay. Four shelves of 0.75 in add 3.00 in to the used height, which is often the difference between a comfortable leftover and a tight one. The planner keeps thickness inside the running total so the reported shelf levels already account for the material that separates one bay from the next, and so the leftover is the genuine unused space rather than an optimistic figure.
The tables below are computed from the formula in the next section for the default inputs: a 72 in cabinet interior, four object heights of 10, 12, 14 and 18 in, a shelf thickness of 0.75 in and a 2 in clearance per bay. They are illustrative planning figures, not measurements of any product or a published standard. Shelf levels are measured upward from the cabinet floor.
| Order (tallest first) | Object height | Bay height (object + 2 in) | Shelf level above cabinet floor |
|---|---|---|---|
| 1 | 18 in | 20 in | 20.75 in |
| 2 | 14 in | 16 in | 37.50 in |
| 3 | 12 in | 14 in | 52.25 in |
| 4 | 10 in | 12 in | 65.00 in |
The four bay heights sum to 62 in. Four shelves at 0.75 in each add 3.00 in, giving 65.00 in used and leaving 7.00 in of the 72 in interior unused. Shelf levels are cumulative, so each row already includes every bay and every shelf below it; the final level of 65.00 in equals the used height.
The second table shows the running used height after each bay, which is the quantity the stopping rule tests at every step.
| Bays included | Sum of bay heights | Shelves | Used height | Leftover of 72 in |
|---|---|---|---|---|
| 1 | 20 in | 1 | 20.75 in | 51.25 in |
| 2 | 36 in | 2 | 37.50 in | 34.50 in |
| 3 | 50 in | 3 | 52.25 in | 19.75 in |
| 4 | 62 in | 4 | 65.00 in | 7.00 in |
The second table makes the stopping rule visible. At each step the used height is the sum of the bay heights so far plus one shelf thickness per bay. The fourth bay brings the used height to 65.00 in, still inside the 72 in interior, so all four bays are kept. If the cabinet were shorter, the first row whose used height exceeded the interior would be the one dropped, along with every row after it.
Every rule below is stated explicitly so that any result can be checked by hand. The arithmetic uses sorting, addition, multiplication and comparison only; no rounding is applied to the reported heights, which are exact sums of the entered values.
The object heights are sorted into descending order, tallest first. For each object, bay height = object height + clearance, with the clearance applied once per bay. For the default set the sorted objects are 18, 14, 12 and 10 in, so the bay heights are 20, 16, 14 and 12 in. The clearance is a commonly used planning figure for lifting an object in and out of a bay, not a measured requirement or a published standard. Because each object produces exactly one bay, the number of candidate bays equals the number of object heights entered.
One shelf is counted for every bay, so shelves = number of bays. The used height is used = sum(bay heights) + shelves × thickness. With the default four bays this is (20 + 16 + 14 + 12) + 4 × 0.75 = 62 + 3.00 = 65.00 in. The thickness is charged per bay rather than once for the whole cabinet, because each bay is separated from the next by a shelf. The leftover is simply leftover = cabinet height − used, which for the default is 72 − 65.00 = 7.00 in. All four figures are reported exactly, with two decimal places where a quarter-inch thickness produces one.
Shelf levels are cumulative sums measured up from the cabinet floor: each level is previous level + bay height + thickness, starting from zero. The default levels are 20 + 0.75 = 20.75 in, then 20.75 + 16 + 0.75 = 37.50 in, then 37.50 + 14 + 0.75 = 52.25 in, and finally 52.25 + 12 + 0.75 = 65.00 in. Bays are added only while the running used height stays at or below the cabinet height; as soon as adding the next bay and its shelf would exceed the interior, the process stops and the remaining objects receive no bay. This is why a shorter cabinet can return fewer shelf levels than the number of objects entered.
Each example below is recomputed from the formulae above with Python, and the numbers can be reproduced inside the tool by entering the same inputs. Example A uses the default entries and therefore reproduces the default output exactly. Examples B and C change the cabinet height and the object set to show how the stopping rule and the leftover respond.
Inputs: cabinet interior height 72 in, object heights 10, 12, 14 and 18 in, shelf thickness 0.75 in, clearance 2 in. Sorted tallest first, the objects are 18, 14, 12 and 10 in, giving bay heights of 20, 16, 14 and 12 in. The bay heights sum to 62 in, and four shelves add 4 × 0.75 = 3.00 in, so the used height is 65.00 in and the leftover is 7.00 in. The four shelf levels are 20.75, 37.50, 52.25 and 65.00 in above the cabinet floor. These values reproduce the tool’s default output exactly and match both reference tables above.
Inputs: cabinet interior height 48 in, object heights 10, 12, 14 and 18 in, shelf thickness 0.75 in, clearance 2 in. The first bay is 20 in and one shelf brings the used height to 20.75 in, inside the 48 in interior. The second bay is 16 in and two shelves give 36 + 1.50 = 37.50 in, still inside. Adding the third bay of 14 in would give 50 + 2.25 = 52.25 in, which exceeds 48 in, so the process stops. Only two bays are kept, the used height is 37.50 in, the leftover is 10.50 in, and the shelf levels are 20.75 and 37.50 in. The 14 and 10 in objects receive no bay in this plan.
Inputs: cabinet interior height 84 in, object heights 8, 10, 12 and 16 in, shelf thickness 0.75 in, clearance 2 in. Sorted tallest first, the objects are 16, 12, 10 and 8 in, giving bay heights of 18, 14, 12 and 10 in. The bay heights sum to 54 in, and four shelves add 3.00 in, so the used height is 57.00 in and the leftover is 27.00 in. The shelf levels are 18.75, 33.50, 46.25 and 57.00 in. All four bays fit with a generous leftover, showing that a taller interior and smaller objects change both the positions and the unused space without altering the method.
Good output depends on good input. A tape measure, a pencil and a notepad are enough for the whole process. Work in inches throughout, and write every figure down with its unit before opening the tool.
Avoid scaling object heights from a photograph or a product illustration unless a dimensioned scale is printed beside it. A small error in the tallest object propagates through the first bay and shifts every shelf level above it, so the largest item is the one worth measuring most carefully.
The model is a one-dimensional vertical plan. It assumes a flat cabinet floor, a fixed interior height, shelves of uniform thickness, and one bay per object placed in descending order of object height. The 2 in clearance and the 0.75 in shelf thickness are commonly used planning conventions or entered values, not a published standard or a regulatory requirement. Entering your actual object heights and material thickness will always produce a better plan than relying on the defaults.
It does not account for shelf depth, cabinet width, shelf material or finish, adjustable shelf holes, door swings, drawers, internal fittings, unequal bay widths, or objects that must be laid flat. It does not consider the shape, fragility or reach of any object, whether a shelf level is comfortable to use, or how a real cabinet is assembled. Those depend on the specific cabinet and on how it is used.
The output is a set of vertical positions, not a cutting list or a purchase decision. When the first bay already exceeds the interior height, no shelf levels are returned and the leftover equals the full cabinet height; that case is reported rather than silently adjusted. Treat every figure as one input alongside the real cabinet dimensions, the actual object heights and a physical check of the space. The tool provides an arrangement only, and no result should be read as professional advice of any kind.
Sorting tallest first gives a determinate plan from a fixed set of inputs: the largest demand is tested while the running used height is still small, and the remaining bays are added against whatever space is left. It removes the need to choose among many possible arrangements, at the cost of not optimising the layout.
It is a commonly used planning allowance added to each object height so the bay is taller than the object, leaving room to lift the item in and out. The default is 2 in, it is applied once per bay, and it is a convention rather than a measured requirement or a published standard.
Each bay is separated from the next by a shelf, so the used height adds one shelf thickness for every bay. Four bays at 0.75 in add 3.00 in. Charging the thickness only once would understate the used height and overstate the leftover.
Bays are added only while the running used height stays within the interior height. As soon as the next bay plus its shelf would exceed the cabinet, the process stops and the remaining objects receive no bay. Example B shows a 48 in cabinet returning two shelf levels from four objects.
No. A shelf level is a cumulative position measured upward from the cabinet floor, and it already includes every bay and shelf below it. Subtract the previous level and one shelf thickness to recover the bay height for that row.
The calculator works in inches. Metric measurements can be converted before entry using 1 in = 2.54 cm, and every result can be converted back with the same factor. Converting at the start keeps the cumulative sums in one unit throughout and avoids a mixed-unit error.
The clearance, thickness and ordering conventions described above are commonly used planning practices rather than a single mandatory standard. The following public references are provided so that the underlying terminology, product dimensions and layout guidance can be checked independently. Links are for verification only and are not an endorsement of any product or retailer, and none of these sources states the specific constants or formulae used here.
This tool provides general planning guidance for informational purposes only. It does not constitute professional interior design advice. Every figure, allowance, dimension and quantity described on this page is a commonly used planning convention, not a building-code requirement or a mandatory standard. Always measure your space, confirm finished dimensions with the retailer, and consult a suitably qualified professional where a specific decision requires one.
[…] Shelf Spacing Planner […]
[…] Shelf Spacing Planner […]