Fence Calculator
Posts, rails, and pickets for a fence run of any length.
Input sheet
DIY at your own risk. Calcora's calculators and guides are general estimates and information only — not professional, engineering, legal, or safety advice. Always verify local building codes and permit requirements, and hire a licensed pro for electrical, gas, plumbing, structural, or any work you're not fully comfortable doing yourself.
A fence is posts, rails, and pickets — three different counts that all flow from one number, the post spacing. This calculator turns a run length into a full materials list so nothing gets forgotten at the lumber yard.
How it works
Length divided by post spacing gives sections; posts are sections plus one. Rails are sections times rails per section; 6 in pickets cover the run.
Length divided by post spacing gives the number of sections; posts are always sections plus one because a run needs a post on both ends. Rails are sections times the rails per section, and pickets are figured at 6-inch widths across the whole run.
Eight-foot spacing is the common default for wood fences — wider sags, tighter costs more. Choose two rails for a short fence and three for taller privacy fences that need the extra rigidity.
Sections = length ÷ spacing, rounded up; posts = sections + 1; rails = sections × rails per section; pickets = (length × 12) ÷ 6.
Worked examples
A 100 ft fence with 8 ft post spacing and 2 rails per section. → 14 posts, 26 rails, 200 pickets.
100 ÷ 8 = 12.5, rounded up to 13 sections. Posts = 14, rails = 13 × 2 = 26, pickets = 1,200 in ÷ 6 = 200.
A 250 ft backyard fence with 8 ft spacing and 3 rails per section. → 33 posts, 96 rails, 500 pickets.
250 ÷ 8 = 31.25, rounded up to 32 sections. Posts = 33, rails = 32 × 3 = 96, pickets = 3,000 ÷ 6 = 500.
Tips & gotchas
- Set corner and gate posts in deeper, wider footings — they take the most stress and are the first to lean if undersized.
- Buy posts a foot or two longer than the finished height so you can sink them below the frost line and trim the tops level.
- Pickets here assume a 6-inch width with no gap; for a spaced 'shadowbox' or picket style, adjust the count for your gap.
- Account for gates separately — a gate opening replaces pickets with a frame and hardware.
FAQ
How far apart should fence posts be?
Eight feet is standard for wood fences and balances cost against sag. Go to 6 feet for tall privacy fences or windy sites where you want extra rigidity.
How deep should I set the posts?
About one-third of the post's above-ground height, or below your local frost line — whichever is deeper. For a 6-foot fence that usually means a 2-foot-plus hole.
How many rails do I need?
Two rails suit fences up to about 4 feet; three rails are standard for 6-foot privacy fences to keep the pickets from warping and the panel from racking.
Related calculators
Concrete Calculator · Paint Calculator · Flooring Calculator · Mulch Calculator · Gravel & Driveway Calculator