Last reviewed: November 6, 2026. Formulas checked against standard industry conversions. How we calculate.
Quick answer: A 10-foot railing with 1.5-inch balusters needs 22 balusters spaced 3.78 inches apart. Enter your railing length, baluster width, and maximum gap below to get the exact count and spacing for your deck.
Deck Baluster Spacing Calculator
Enter your railing length and baluster size to work out how many balusters you need.
How the Deck Baluster Spacing Calculator Works
Balusters are spaced so the gaps between them stay under the building-code maximum. This calculator works out how many balusters fit and then shares the leftover space evenly across all the gaps.
- Convert the railing length from feet to inches.
- Add the baluster width and the maximum gap to get the space one baluster plus one gap takes up.
- Divide the railing length by that number and round up to get the number of balusters.
- Share the leftover space across all the gaps. There is one more gap than balusters, because there is a gap at each end.
Balusters = ceiling(railing length in inches / (baluster width + maximum gap))
Actual spacing = (railing length in inches – balusters x baluster width) / (balusters + 1)
Worked Examples
Example 1: 10-foot railing, 1.5-inch balusters, 4-inch maximum gap
Railing length = 120 inches. Balusters = 120 / (1.5 + 4) = 21.82, rounded up to 22. Actual spacing = (120 – 22 x 1.5) / 23 = 87 / 23 = 3.78 inches.
Example 2: 8-foot railing, 2-inch balusters, 4-inch maximum gap
Railing length = 96 inches. Balusters = 96 / (2 + 4) = 16. Actual spacing = (96 – 16 x 2) / 17 = 64 / 17 = 3.76 inches.
Balusters Needed by Railing Length
Baluster counts for 1.5-inch balusters with a 4-inch maximum gap:
| Railing length | Balusters needed | Actual spacing |
|---|---|---|
| 8 ft | 18 | 3.63 in |
| 10 ft | 22 | 3.78 in |
| 12 ft | 27 | 3.70 in |
The 4-Inch Rule
Building codes in the US require guardrail openings that a 4-inch sphere cannot pass through, so the gap between balusters must be 4 inches or less. This calculator uses 4 inches as the default maximum gap, and the actual spacing it returns always comes out under the maximum you enter. Measure the railing between the posts, not post to post, and run each railing section separately.
Frequently Asked Questions
What is the maximum spacing between deck balusters?
4 inches. Building codes require guardrail gaps that a 4-inch sphere cannot pass through, so balusters must be spaced 4 inches apart or less.
How do you calculate baluster spacing?
Divide the railing length in inches by the baluster width plus the maximum gap, and round up to get the number of balusters. Then work out the actual spacing as (railing length – balusters x baluster width) / (balusters + 1), counting a gap at each end.
How many balusters do I need for a 10-foot railing?
With 1.5-inch balusters and a 4-inch maximum gap, a 10-foot railing needs 22 balusters spaced 3.78 inches apart.
Do I count the gaps at the ends?
Yes. There is a gap between the first baluster and the post, and another between the last baluster and the post, so the number of gaps is one more than the number of balusters.
What if my railing has a post in the middle?
Measure each section between posts separately and run the calculator once per section. Each section gets its own baluster count and spacing.
Related Calculators
Try the Deck Calculator, the Deck Stair Calculator, and the Deck Stain Calculator.