How many fence posts you need
Post count is posts = ceil(length ÷ spacing) + 1, because a run of fence needs one post at each end plus one between each pair of sections. A 100 ft fence at 8 ft spacing needs 14 posts and 13 sections.
How to use this calculator
Enter the total fence length and your post spacing in feet. The result shows posts and sections. For a deck railing instead, the board count is sized by the deck boards calculator. If you are setting tube forms, the sonotube calculator gives the volume per hole.
Spacing and gates
Wood fences typically use 6–8 ft spacing; vinyl panels are fixed length. Add posts for each gate and corner. Set posts in concrete — size the footing volume with the concrete calculator.
Measure the run along the ground and mark every post position before you dig, so any leftover distance is shared across the sections. On sloped ground, decide early whether the fence will step down in level panels or follow the contour, because stepped fences need taller posts at the low end of each step. Corners, ends and gate posts carry far more load than line posts, so use a heavier post and a deeper footing at each of them. On sloping ground, work out the fall first with the elevation grade calculator.
Frequently asked questions
- How do I calculate fence posts?
- Divide fence length by post spacing, round up for sections, then add one post for the closing end.
- How far apart should fence posts be?
- Wood fences usually use 6–8 ft spacing; vinyl and pre-built panels have a fixed length.
- Do gates need extra posts?
- Yes, gates and corners each need their own posts, so add them to the calculated count.
- How deep should fence posts be set?
- About one-third of the post height, usually 2–3 ft, set in concrete for stability.
- What if the fence length is not a whole number of sections?
- Spread the difference evenly across all the sections rather than leaving one short panel at the end. Reducing 8 ft spacing to 7 ft 9 in over a whole run is invisible; a 3 ft stub panel is not.