Fence Calculator
Work out how many fence posts, rails, pickets and bags of concrete you need for your fence, plus total material cost in USD.
Fence Calculator: Posts, Rails, Pickets and Concrete
Before you order a single fence post, you need a real materials list — not a rough guess scribbled on the back of an envelope. This fence calculator works out exactly how many posts, rails, pickets and bags (or cubic metres) of concrete you need to build a picket or privacy fence, based on the actual run length, height and spacing you plan to use.
Most online fence calculators stop at counting pickets. This one goes further: it sizes the post holes, works out how deep to dig them, and converts that into a concrete volume for the footings — because getting the post depth wrong is the single most common reason a fence leans or heaves within a few years.
Whether you're fencing a back garden, a plot boundary or a full property line, the same three questions drive the whole take-off: how far apart are the posts, how tall is the fence, and how wide are the gaps between pickets? Answer those and the calculator returns a full bill of materials plus an estimated total cost.
The formulas below are the same ones a fencing contractor uses to quote a job — no rules of thumb pulled out of thin air. Change any input and the post count, rail count, picket count and concrete volume update immediately, so you can compare a 1.8 m fence against a 2 m fence, or 2 m post spacing against 3 m, before you spend anything.
How to use the fence calculator
- Enter the total fence length — the full run you're fencing, in metres or feet.
- Set the post spacing (on-centre) — most timber fences use 2–2.5 m (6–8 ft); check your post/panel supplier's recommended maximum span first.
- Enter the fence height, measured from ground level to the top of the fence.
- Choose the number of rails per section — 2 for a low fence, 3 for a standard 1.8 m privacy fence, more for taller or windier sites.
- Enter picket width and the gap you want between pickets (0 for a solid privacy fence, a few centimetres for a semi-open picket fence).
- Pick your post shape — cylindrical (round) or cuboid (square/rectangular) — and its diameter or width/thickness.
- Set a waste allowance (5–15%) to cover offcuts, damaged pickets and cutting losses.
- Read off the results: total posts, rails, pickets, concrete volume per post and in total, and the estimated material cost.
The maths behind the fence calculator
The calculator works in five stages: post count, post length, rail count, picket count, and concrete volume. Each one follows directly from the fence length, height and spacing you enter.
Post count uses on-centre spacing along the run: posts = ceil(fence length ÷ post spacing) + 1. The "+1" is the classic fencepost-counting rule — a run divided into N sections always needs N+1 posts, because a post sits at both ends as well as at every spacing interval in between. Sections = posts − 1.
Post length (the length you actually buy) is 1.5 × the finished fence height, because roughly one-third of the post is buried below ground for stability. Post depth (hole depth) is therefore post length ÷ 3, which also equals half the fence height.
Total rails = rails per section × number of sections. Total pickets = ceil(fence length ÷ (picket width + picket gap)), then increased by your waste percentage and rounded up, since you can only buy whole pickets.
Concrete volume depends on post shape. For a square/cuboid post, the standard rule of thumb is a post hole three times the post's width and thickness on each side; subtracting the volume the post itself displaces gives concrete = 8 × width × thickness × depth. For a round post, a hole diameter three times the post diameter gives concrete = 2π × diameter² × depth.
Worked example: a 30 m run of fence, posts every 2.5 m, 1.8 m high, 3 rails per section, 10 cm-square posts, 10% waste. Posts = ceil(30 ÷ 2.5) + 1 = 13. Sections = 12. Rails = 3 × 12 = 36. Post length = 1.8 × 1.5 = 2.7 m, so post depth = 0.9 m. Concrete per post = 8 × 0.10 × 0.10 × 0.9 = 0.072 m³, so 13 posts need roughly 0.94 m³ of concrete in total — before pickets are even counted.
Typical post spacing by fence style
- Timber picket/privacy fence (panel or board-built): 2.0–2.5 m (6–8 ft) between posts is the most common range for standard-height residential fencing.
- Post-and-rail (agricultural/paddock) fencing: posts are often spaced wider, 2.4–3.0 m (8–10 ft), since the rails carry less infill weight.
- Chain-link fencing: line posts every 3 m (10 ft) is a common trade default, with heavier terminal/corner posts at both ends and at every direction change.
- Panel fencing (pre-built panels, common across Europe/UK/Australia): post spacing is fixed by the panel width itself — typically 1.8 m or 1.83 m (6 ft) panels — rather than chosen independently.
- Taller fences, exposed/windy sites, and heavier infill (solid boards vs. open pickets) all push post spacing toward the shorter end of these ranges; always check your specific post and panel manufacturer's span table before finalising a plan.
US frost-line and permit notes
Post-hole depth in the US is governed less by a single national rule than by local frost depth, which varies enormously — from essentially zero along the Gulf Coast to 4 ft (1.2 m) or more across the northern tier and mountain states. Local building departments publish a frost-line depth for footings, and it's worth checking that figure against the one-third-of-post-length rule used above before you dig, especially for a fence that has to survive freeze-thaw cycles over many winters.
Most US municipalities require a permit for a fence over a certain height (often 6 ft/1.8 m in a backyard, sometimes lower in a front yard), and HOA covenants frequently add their own material and height restrictions on top of that — check both before setting posts.
Pro tips and common mistakes
At a typical US retail price of around $18 per post, the worked example above (13 posts for a 30 m/~98 ft run) would run roughly $234 in posts alone, before rails, pickets and concrete mix are added — use the calculator's cost output for a complete total in USD.
US trade terminology: "fence posts" (not "fencing stakes"), "pickets" for the vertical infill boards, "rails" (not "purlins") for the horizontal framing members, and "concrete mix" sold by the bag (60 lb / 80 lb) rather than by the cubic metre — the calculator's cubic-metre output converts easily to bag counts using your mix manufacturer's yield-per-bag figure.
- Reinforce corner, gate and end posts. These carry far more lateral load than a straight-run line post — use a larger post section and/or a deeper, wider footing at every corner, gate opening and terminal post.
- Dig below the frost line in cold climates. In regions with ground frost, a post hole shallower than the local frost-line depth lets frost heave push the post upward over winter, tilting the whole fence line within a few seasons — check your local building department's frost-depth guidance, not just the generic "one-third of post height" rule used here.
- Slope the top of each concrete footing away from the post. A footing poured flush with grade traps water against the buried timber and accelerates rot — crown the concrete slightly so water sheds away from the post.
- Don't skip the waste allowance. Pickets split when nailed near the end, boards get cut wrong, and corner sections rarely use whole pickets — a 10% buffer is standard trade advice for a reason.
- Check your boundary before you dig. Confirm the actual property line (not just a fence line inherited from a previous owner) and any local permit or height-restriction rules before setting posts — moving a fence after the concrete has cured is expensive.
- Common mistake: spacing posts too far apart to "save on posts." Every material calculator will happily compute the smaller post count, but a rail spanning too far will sag or bow within a year — stay inside your rail/panel manufacturer's recommended span.


