Baluster spacing calculator

Measure the rail section between the posts, not post center to post center. You get the fewest balusters that keep every gap under your maximum, spaced evenly.

Enter your measurements

On a stair, pick the stair option and measure along the sloped rail.
in
Level: 6 ft centers with 4×4 posts = 68½ in. Stair: measure along the rail, post face to post face.
in
2×2 = 1½ in; round metal ≈ ¾ in
in
US: keep deck gaps under 4 in; on the open side of a stair the IRC allows up to 4-3/8 in. UK: under 100 mm.
More options: Layout
An odd count puts a baluster in the middle, an even count a gap. Matching every section looks tidier.
Balusters per section13 balusters
Gap (cut your spacer to this)3-1/2 in
Exact gap (decimal)
3.5 in
Middle of the section
A baluster, centered
Balusters for all sections
13 balusters
Center-to-center spacing
5 in
Post face to first baluster center
4-1/4 in
Screws (2 top, 2 bottom each)
52 screws
How we got this

(68-1/2 in − 3-3/4 in) ÷ (1-1/2 in + 3-3/4 in) = 12.33 → round up to 13 balusters

(68-1/2 in − 13 × 1-1/2 in) ÷ 14 gaps = 3-1/2 in (3.5 in)

  • Balusters and 2×2s are not perfectly uniform. Measure a few, and cut a spacer block to the exact gap instead of measuring each one.
Check your codeCode limits vary by jurisdiction — confirm with your building department before you cut or build. (IRC R312)

For this job · affiliate link
Cordless drill/driver kit52 screws, each within an inch of a baluster end — pre-drill every one or the 2×2s split. A drill and a driver (or two batteries) makes it one pass.
View on Amazon (opens in a new tab)

Next: Building the steps too? Lay out the stair stringers.

Quick answers for common sizes

Worked examples for the Baluster Spacing Calculator
ExampleAnswer
How many balusters for a 6 ft railing section13 balusters
How many balusters for an 8 ft railing section17 balusters

Balusters by section length (same baluster and max gap)

Balusters by section length (same baluster and max gap)
Space between postsBalusters per sectionGap (cut your spacer to this)Center-to-center spacing
44.5 in (4 ft post centers)8 balustersa hair under 3-5/8 in5-1/8 in
56.5 in (5 ft post centers)11 balustersa hair over 3-5/16 in4-13/16 in
68.5 in (6 ft post centers)13 balusters3-1/2 in5 in
80.5 in (7 ft post centers)15 balusters3-5/8 in5-1/8 in
92.5 in (8 ft post centers)17 balustersa hair under 3-3/4 in5-1/4 in

The balusters are spread evenly with a gap at each post, so the layout is symmetrical. New to this? Words explained.

How the spacing is worked out

A section between two posts holds n balusters and n + 1 gaps (one at each post). Find the smallest n that keeps the gap under your maximum, then divide the leftover space evenly.

Front view of a deck railing section between two posts, with thirteen evenly spaced balusters, labelled post, gap, baluster width, section length and a 4 inch sphere that does not fit through a gap.
One railing section between two posts. With a gap against each post, n balusters leave n + 1 equal gaps; measure the section from post face to post face, and keep every gap small enough that a 4 in sphere can’t pass (IRC R312.1.3).
n = (section − max gap) ÷ (baluster + max gap), rounded up
exact gap = (section − n × baluster) ÷ (n + 1)
first baluster center = gap + ½ baluster, from the post face

Example: a 6 ft section with 4×4 posts is 72 − 3½ = 68½ in between posts. With 1½ in balusters and a 3¾ in maximum: (68.5 − 3.75) ÷ 5.25 = 12.3, so 13 balusters. The exact gap is (68.5 − 19.5) ÷ 14 = 3½ in. That layout is worked through on How many balusters for a 6 ft railing section; an 8 ft post spacing, where the gap falls between tape marks, is on How many balusters for an 8 ft railing section.

Baluster centered or gap centered?

With a gap against each post the layout is always symmetrical, and the count decides what lands in the middle: an odd number of balusters puts one dead center, an even number leaves a gap there. The 6 ft example above has 13, so a baluster is centered. If you want every section to look the same, pick the layout under More options; the calculator adds a baluster when needed, which only makes the gaps smaller. To lay out from the middle, mark the center of the rail, set the first baluster (or the first gap) on it, and work out toward both posts with the spacer.

Stair railings

Balusters on a stair stand plumb, so the gap that matters is measured level, even though the rail slopes. The calculator takes the section measured along the rail and multiplies by the cosine of the rail angle to get its level length, then spaces the balusters on that. The rail angle comes from the step height and depth: atan(rise ÷ run). For marking, divide the level spacing by the same cosine to get the distance between marks along the sloped rail.

Example: 7½ in steps with a 10½ in run slope at about 35.5°. A rail section of 68½ in measured along the slope is about 55¾ in level, which takes 10 balusters of 1½ in with gaps a hair over 3-11/16 in — marked 6-3/8 in apart along the rail. On the open side of a stair the IRC allows openings up to a 4-3/8 in sphere instead of 4 in, and the triangle below the bottom rail, formed by each riser and tread, up to 6 in.

Code rules for guards (check yours)

Summarised from the 2021 International Residential Code, Chapter 3 (R312 guards), and from England’s Approved Document K. Jurisdictions amend these — check yours.
ItemRule
US homes (IRC R312.1.3)A 4 in sphere must not pass through any opening in the guard
US stairs (IRC R312.1.3)Guards on the open side of stairs: 4-3/8 in sphere; the triangle formed by the riser, tread and bottom rail: 6 in sphere
Guard height (IRC R312.1.2)36 in minimum; 34 in on the open sides of stairs, measured from the nosing line
When a guard is needed (IRC R312.1.1)Walking surface more than 30 in above the grade below, within 36 in horizontally of the edge
England (Approved Document K)A 100 mm sphere must not pass through; also avoid climbable designs where children are present
CautionRailings are life-safety items. Post attachment, rail strength and height are set by your local code — this calculator only lays out the balusters.

Layout tips

  • Aim a little under 4 in. Wood balusters bow and shrink, so a 3¾ in design gap can grow. Many builders target about 3½ in.
  • Cut a spacer. Rip a scrap to the exact gap and use it between every baluster — faster and more even than a tape.
  • Measure every section. Posts are rarely placed perfectly; one section may need a different count.
CalculatorStair Stringer Calculator →Building the steps as well?

What you’ll need

As an Amazon Associate we earn from qualifying purchases. Links to products are affiliate links — they cost you nothing extra and help keep these calculators free.

Frequently asked questions

How many balusters for a 6 ft railing section?

Thirteen 2×2s with an even 3½ in gap between 4×4 posts on 6 ft centers — see How many balusters for a 6 ft railing section.

How many balusters for an 8 ft railing section?

Seventeen 1½ in balusters with gaps a hair under 3¾ in (3.72 in) — see How many balusters for an 8 ft railing section.

What is the maximum baluster spacing?

Under IRC R312.1.3, used in most of the US, a 4 in sphere must not pass through the railing, so gaps must be under 4 in. Guards on the open side of a stair may allow up to a 4-3/8 in sphere. England uses a 100 mm sphere. Check your local code.

How do you space balusters on a stair railing?

Space them on the level length of the section — the length along the rail times the cosine of the rail angle — because the balusters stand plumb and the gap is measured level. Then mark the spacing along the rail, which is the level spacing divided by the same cosine. Pick “Stair” in the calculator and it does both.

How many balusters per linear foot?

With 1½ in balusters and about 3½ in gaps, a little under 2½ per foot — roughly 2.4. Use the calculator for an exact count per section.

Sources