Fence Calculator — posts, rails and pickets
Posts, rails, pickets and fasteners for a wood fence, cut from the dressed sizes PS 20 sets and honest about which of the other numbers are only convention.
Quick answer: posts, pickets and rails for a privacy fence
| Fence | Posts | 1×6 pickets | Rails (16 ft boards) |
|---|---|---|---|
| 16 ft | 3 | 35 | 6 (3 boards) |
| 24 ft | 4 | 53 | 9 (5 boards) |
| 50 ft | 8 | 110 | 21 (11 boards) |
| 100 ft | 14 | 219 | 39 (20 boards) |
| 150 ft | 20 | 328 | 57 (29 boards) |
8 ft bays on 4×4 posts, dry 1×6 pickets (5½ in.) butted tight, 3 rails per bay cut from 16 ft boards, two rails to a board. A gate adds one post and takes its width out of the run.
| Sections and posts | — |
|---|---|
| Last section | — |
| Picket module | — |
| Pickets | — |
| Rails | — |
| Rail stock and cut plan | — |
| Fasteners | — |
| Concrete for the posts | — |
“Two rails under five feet, three above” is not published anywhere. It is repeated on every fence page on the internet and it comes from nothing. What does exist: Universal Forest Products' own installation sheet, which says three rails for a 6 ft fence and four for an 8 ft fence, and two for “shorter fences” without ever defining shorter. Some municipalities legislate a rail count against height and opacity, and they do not agree with each other or with the five‑foot rule. There is no model‑code provision at all, and there is a reason for that: IRC R105.2 exempts fences not over 7 ft from needing a permit, so the residential code never gets as far as specifying how they are framed. That is why the rail count above is a field you fill in rather than a number this page asserts.
A 1×6 is not six inches, and it is not always 5½ either. The American Softwood Lumber Standard, PS 20‑25, Table 3, dresses a nominal 1×6 to 5½ in when it is graded dry — but to 5⅝ in when it is graded green, and §6.2.5 gives redwood, western red cedar and northern white cedar their own green width of 5⅞ in. Fence boards are very often both cedar and green. On a 100 ft butted privacy run that is 1,200 in of face: at 5½ you need 219 pickets, at 5⅝ you need 214. Five pickets is not a rounding error when it is the difference between finishing and driving back to the yard. Read the grade stamp, or measure one.
Post spacing is a lumber decision dressed up as a structural one. Eight feet on centre is everywhere because rails are sold in 8 and 16 ft lengths, so 8 ft spacing wastes nothing. The published sources say the same thing without the structural story: the USDA NRCS conservation practice specification for board fence caps posts at 8 ft on centre, and the municipalities that legislate spacing land on 8 ft too. None of that is a national standard and none of it is a wind calculation. A taller or a more solid fence catches more wind, and nothing in these documents accounts for it. Treat 8 ft as the default that suits the material, and go tighter if your fence is tall, solid, or exposed.
A rail is not as long as the spacing, and stock is not exactly its length. Rails land between the posts, so at 8 ft on centre with a 4×4 the rail is 8 ft less 3½ in, and the cut plan above is worked on that figure rather than on the spacing. In the other direction, PS 20‑25 §5.3.2 requires lumber up to 2 in nominal thickness to be double‑end‑trimmed to not less than its nominal length and not more than 3 in over, so a 16 ft rail is somewhere between 16 ft‑0 and 16 ft‑3. That slack is real, and it is never enough to get one more full rail out of a stick, which is why this page plans cuts on the nominal length and not on the hopeful one.
Seven feet is the line that matters. IRC R105.2 exempts fences not over 7 ft high from requiring a building permit. Above that, you need one. The same section is explicit that being exempt from a permit does not exempt the work from complying with the code, and none of this touches your local zoning, which is a separate rulebook and is usually the one that cares about height at the street. Pool barriers are a different matter again and are not what this page is for.
What the gate assumption is. Each gate opening is taken out of the fence run and adds one post, on the basis that a gate needs a post on each side and one of those is a line post you were building anyway. A gate leaf is not counted in the picket total: gates are usually bought as a unit or built with their own bracing, and counting their pickets in with the fence quietly inflates the order. If you are building the leaves, add their width back in as extra run.
What I check on a job
What I check before trusting the count. The length I type in is never the length on the survey. I walk the line with a tape once the stakes are in, because the fence stops short of a property corner, jogs around a tree, or dies into an existing wall. The page treats the run as one straight line, so I run it once per leg, enter the gate only on the leg it sits in, then take one post off the sum for every corner two legs share and every end that butts a wall. Then I read the "Last section" row. When the run does not divide evenly, I either spread the spacing so the bays come out even, as the page suggests, or keep full bays and hide the short one at a corner or behind a shed. Last, I check whether the gate width is the clear opening the owner asked for or the size of a gate already bought, because the page subtracts exactly what I enter.
Every lumber dimension comes from NIST Voluntary Product Standard PS 20‑25,
American Softwood Lumber Standard (January 2025), Table 3: nominal 1×4 dresses dry to
3½ in and green to 3⅞ in; nominal 1×6 dresses dry to 5½ in and
green to 5⅝ in; nominal 2 in thickness dresses dry to 1½ in; a 4×4
dresses dry to 3½ in square, and a 6×6 to 5½ in square under the timber rule
regardless of moisture content. §6.2.5 and Table 5 give redwood, western red cedar and
northern white cedar a green nominal‑6 width of 5⅞ in. §5.3.2 sets the
double‑end‑trim tolerance of +0 to +3 in on length. The standard states the inch
values are the units of record.
Rails per fence height comes from the Universal Forest Products fence installation instructions:
three rails for a 6 ft fence, four for 8 ft, and nothing at all for shorter fences. The
instructions do not say. Post spacing comes from the
USDA NRCS Conservation Practice Specification, Fence (Code 382), Illinois corral and lot
fence specifications: space posts no more than 8 ft apart. Permit threshold comes from
International Residential Code R105.2, work exempt from permit: fences not over 7 ft (2134 mm)
high, unchanged from the 2021 to the 2024 edition.
Deliberately not asserted: a fastener count per picket. The only published fastening requirement found
is the NRCS one for a horizontal board nailed to a post in agricultural fence: two fasteners at each
intersection. That is not the same joint as a vertical picket on a rail. The field is
therefore yours, prefilled with that figure and labelled as borrowed. Stock lengths of 8 to 20 ft
in two‑foot steps are a yard convention: PS 20 standardises only that lengths come in
one‑ or two‑foot multiples and leaves the list to each grading agency.
Worked example
100 ft of 6 ft privacy fence with one 4 ft gate, posts at 8 ft: posts, pickets, rails?
- Fence run = 100 − 4 = 96 ft: 12 bays at 8 ft, 14 posts including the gate posts.
- Pickets 5-1/2 in actual, butted: 96 × 12 ÷ 5.5 = 210.
- 3 rails × 12 bays = 36 rails; cut 2 to a 16 ft stick = 18 sticks.
14 posts, 210 pickets, 36 rails from 18 sticks, and 1,260 fasteners. With no gate: 13 bays and 219 pickets. The post count links straight into the concrete page.
15 values on this page were driven in a browser and compared with independently derived figures on 2026-10-29 (2808 values across 228 calculators site-wide).
Questions
How many posts for 100 ft of fence at 8 ft spacing?
14 including gate posts, with a 4 ft gate taken out of the run: 96 ft is 12 bays, 13 posts, plus one for the gate.
How many pickets per foot of privacy fence?
About 2.2 for 5½-inch pickets butted tight: 12 ÷ 5.5. A 96 ft run is 210 pickets.
How many rails does a 6 ft fence need?
Universal Forest Products' installation sheet says three for a 6 ft fence and four for an 8 ft fence. The "two rails under five feet" rule repeated online is not published anywhere, and no model code sets it: IRC R105.2 exempts fences not over 7 ft from a permit. That is why the rail count is a field you fill in.
Why are fence posts 8 ft apart?
Because rails are sold in 8 and 16 ft lengths, so 8 ft on centre wastes nothing. It is a lumber decision more than a structural one; a different spacing works if the rails are cut to it.