Spindle Spacing Calculator
Calculate spindle spacing accurately for your build. Get material quantities, waste allowances, and project cost breakdowns.
Spindle Spacing Calculator
Calculator
Adjust values & calculateEnter your values below. Every result is computed in your browser โ no data is sent to any server.
Formula: Actual Gap = (Usable Length - Spindles x Width) / (Spindles + 1)
Worked example โ 17 spindles with 3.722-inch gaps (code compliant)
Formula
Actual Gap = (Usable Length - Spindles x Width) / (Spindles + 1)
Subtract the post width from the total section length to get usable length. Calculate the minimum number of spindles needed so that the gap does not exceed code maximum (typically 4 inches). The number of gaps equals the number of spindles plus one. Divide remaining space evenly among all gaps for uniform spacing.
Worked Examples
Example 1: Standard 8-Foot Deck Section
Problem:Calculate spindle spacing for a 96-inch section between two 3.5-inch posts using 1.5-inch wide spindles with a 4-inch max gap.
Solution:Usable length = 96 - 3.5 = 92.5 inches Min spindles = ceil((92.5 - 4) / (1.5 + 4)) = ceil(16.09) = 17 Gaps = 17 + 1 = 18 Actual gap = (92.5 - 17 x 1.5) / 18 = 3.722 inches
Result:17 spindles with 3.722-inch gaps (code compliant)
Example 2: Short Stair Section
Problem:Calculate spindle spacing for a 36-inch stair section between posts using 0.75-inch metal balusters with 4-inch max gap.
Solution:Usable length = 36 - 3.5 = 32.5 inches Min spindles = ceil((32.5 - 4) / (0.75 + 4)) = ceil(6.0) = 6 Gaps = 7 Actual gap with 6 spindles = (32.5 - 6 x 0.75) / 7 = 4.00 inches That is exactly the limit, and the IRC rule is that a 4-inch sphere must not pass, so a gap of precisely 4.00 inches is not compliant. Add one spindle: 7 spindles, 8 gaps = (32.5 - 7 x 0.75) / 8 = 3.41 inches
Result:7 spindles with 3.41-inch gaps (6 spindles would land exactly on the 4-inch limit)
Frequently Asked Questions
What is the maximum spacing allowed between deck or stair spindles?
The International Residential Code (IRC) requires that balusters or spindles be spaced so that a 4-inch sphere cannot pass through any opening. This means the clear gap between spindles must be less than 4 inches. This requirement applies to deck railings, stair railings, and balcony guards. Local building codes may have stricter requirements, so always check with your local building department before starting construction.
How do I calculate equal spindle spacing across a railing section?
First measure the total distance between the inside edges of your posts. Then determine how many spindles you need by dividing the usable length minus one gap by the sum of one spindle width plus one gap, and rounding up. The number of gaps is always one more than the number of spindles. Divide the remaining space after subtracting all spindle widths by the number of gaps to find the exact spacing. This ensures perfectly equal spacing across the entire section.
What is the standard width of a deck spindle or baluster?
Standard wood balusters for decks are typically 1.5 inches square, which is the actual dimension of a standard two-by-two piece of lumber. Metal balusters are usually three-quarter inch to 1 inch in diameter. Square aluminum or steel balusters commonly measure three-quarter inch per side. When calculating spacing, always use the actual measured width of your specific balusters rather than the nominal size, as this affects the final gap calculation.
Should I measure spindle spacing from center to center or edge to edge?
Building codes specify the maximum clear opening between spindles, which is measured edge to edge (the gap). However, when laying out your spindles for installation, center-to-center measurements are more practical because they account for the spindle width and produce evenly spaced results. Spindle Spacing Calculator provides both measurements. Mark your center-to-center distances on the top and bottom rails for the most accurate installation with consistent spacing throughout.
Why is the guard opening rule written as a sphere rather than a flat dimension?
A sphere test catches every shape of opening, not just the neat rectangle between two plumb balusters. Guards contain triangular gaps where a bottom rail meets a stair stringer, wedge-shaped openings around newels, and slots at the ends of a run, and a simple width limit would say nothing about them. Because the criterion is that a sphere of the stated size cannot pass through, it applies equally to every one of those. Codes commonly treat the triangular opening at the tread and riser separately, so check the edition your jurisdiction has adopted.
How does horizontal cable or glass infill compare with vertical spindles?
The opening limit is identical, because it is defined by a sphere that must not pass through the guard, but the geometry that satisfies it is different. Cable infill is set out as a vertical pitch between runs rather than a horizontal pitch between balusters, and tensioned cable spreads apart under load, so intermediate pickets are normally added to limit deflection. Glass panels close the opening altogether and move the problem to panel support and edge clearance. Some jurisdictions also restrict climbable horizontal infill on guards, so check the adopted rule.
How does the layout change on a raking stair rail?
Balusters stay plumb even though the rail slopes, so the opening the sphere has to pass through is the horizontal clear distance, not the distance measured along the rail. For a rail at angle theta, a centre-to-centre spacing of d measured along the slope gives only d times cos(theta) horizontally, so a layout copied from a level section onto the rake produces tighter openings than intended. That errs on the safe side but uses more balusters, so it is worth setting out the rake from horizontal spacing directly.
Why is the actual gap usually smaller than the maximum you entered?
Spindle count has to be a whole number. The routine finds the smallest count that keeps every opening within the limit, then redistributes the leftover space evenly, so the finished gap lands at or below the target rather than exactly on it. Adding one more spindle beyond that count tightens every gap further and keeps the run even; removing one pushes the openings past the limit. This is also why a small change in section length can shift the count by a whole spindle.
Should nominal or actual baluster width be used in the layout?
Always the measured dimension. A two-by-two spindle is nominally 2 in but actually about 1.5 in, and composite or sleeved metal balusters vary between manufacturers. Errors here compound: an eighth of an inch of width error repeated across twenty spindles walks the last one two and a half inches out of position. For the same reason, mark the layout as running cumulative dimensions from one post rather than stepping a single spacing off the previous mark.
How does post width enter the calculation?
The spindles occupy only the clear opening between the posts, so the post material has to come out of the overall dimension first. If the section length was taken from the centre of one post to the centre of the next, subtracting one full post width removes half a post at each end and leaves the true face-to-face opening. If the length was measured between the inside faces of the posts, that subtraction has already happened and the post width entry should be zero.
References
Background & Theory
History
Reviewed for accuracy by Abdullah, Technical Content Specialist ยท Editorial policy
Related Calculators
๐งฎSlab Control Joint Spacing Calculator
Calculate slab control joint spacing with inputs, formulas, and instant results.
๐งฎSlab Rebar Spacing Calculator
Calculate slab rebar spacing with inputs, formulas, and instant results.
๐งฎRebar Spacing Calculator
Calculate rebar spacing with inputs, formulas, and instant results.
๐งฎFence Post Spacing Calculator
Calculate optimal fence post spacing and total post count from fence length and terrain.
๐งฎJoist Span Calculator
Determine maximum joist span from lumber size, spacing, species, and load requirements.
๐งฎRain Gutter Size Calculator
Calculate gutter size and downspout spacing from roof area and local rainfall intensity.
๐งฎTile Grout Calculator
Calculate the amount of grout needed from tile size, spacing, and area.
๐งฎRecessed Lighting Layout Calculator
Calculate spacing and quantity for recessed lights based on room size and ceiling height.