How to use the fence calculator
A timber fence is posts set in the ground, rails running between them and boards, pickets or ready-made panels fixed to the rails. Once you know the length, height and post spacing, everything else follows. This calculator works through the count for each part, the post length to buy and the concrete for the holes, so you can price the fence or write up a materials list.
- Choose units. US mode takes feet for the fence and inches for the parts; metric mode takes metres and millimetres.
- Enter the total length of all runs, including gate openings, plus the height above ground and the post spacing.
- Count corners and gates. Each corner and each gate adds a post; gate openings are taken out of the fenced length.
- Pick the infill. For pickets or boards, enter the width and gap (zero for a solid privacy fence). For panels, one panel fills each section.
- Set the rails and the post hole, then read the results.
Fence material formulas
Fenced length = total length − gates × gate width
Sections = ⌈fenced length ÷ post spacing⌉
Posts = sections + 1 + corners + gates
Rails = sections × rails per section × (1 + extra %)
Pickets = ⌈fenced length ÷ (picket width + gap)⌉ × (1 + extra %)
Post length = height + hole depth, rounded up to stock
Concrete per post = π × (hole diameter ÷ 2)² × depth − post area × depth
The post count assumes each corner and gate breaks the run, which matches most layouts. A fence that closes on itself in a full loop needs one post fewer. Bag yields are typical: about 0.375 ft³ for 50 lb, 0.45 ft³ for 60 lb and 0.60 ft³ for 80 lb bags, and about 0.012 m³ for a 25 kg bag. Check the bag you buy.
| Fence height | Typical post spacing | Typical rails | Typical post set depth |
|---|---|---|---|
| 3–4 ft (0.9–1.2 m) | 6–8 ft (1.8–2.4 m) | 2 | 2 ft (600 mm) |
| 5 ft (1.5 m) | 6–8 ft (1.8–2.4 m) | 3 | 2–2.5 ft (600–750 mm) |
| 6 ft (1.8 m) | 6–8 ft (1.8–2.4 m) | 3 | 2–3 ft (600–900 mm) |
These are common rules of thumb. Frost depth, soil, wind exposure and local rules can call for deeper or closer posts.
Worked examples
A 6 ft privacy fence
A 100 ft fence, 6 ft high, with one corner and one 4 ft gate, posts at 8 ft and 5.5 in boards butted tight. The fenced length is 96 ft, so there are 12 sections and 15 posts. Three rails per section is 36 rails, 38 with 5% extra. The boards are ⌈1,152 ÷ 5.5⌉ = 210, or 221 with extra. Set 24 in deep, each post is 8 ft long. A 10 in hole 24 in deep, less a 3.5 in post, holds about 0.92 ft³ of concrete, two 80 lb bags per post. Across 15 posts that is 13.8 ft³, or 31 bags of 60 lb if you mix by the barrow rather than bag by bag.
A metric panel fence
A 30 m garden fence, 1.8 m high, with posts at 1.83 m for standard panels, two corners and no gate. That is ⌈30 ÷ 1.83⌉ = 17 panels and 17 + 1 + 2 = 20 posts. With 600 mm deep holes, 2.4 m posts work. A 300 mm hole 600 mm deep around a 100 mm post holds about 0.036 m³ of concrete, so 0.73 m³ for all 20 posts, or about 61 bags of 25 kg.
Who this calculator helps
- Landscape architects and garden designers scheduling boundary fences and screens on a site plan.
- Architects adding early quantities for boundary treatments to a cost plan.
- Fencing contractors putting together a quick materials list for a quote.
- Homeowners pricing a new fence or a replacement before visiting the lumber yard.
Practical tips
- Confirm the boundary line, and call your utility locating service before digging any holes.
- Put a few inches of gravel in the bottom of each hole for drainage, and slope the top of the concrete away from the post.
- Brace gate posts well and consider larger posts for gates wider than about 4 ft.
- Get more accurate concrete figures with the concrete calculator, price the lumber with the board foot calculator, and check setbacks with the setback calculator.
Want to see the new fence before you build it? Try it on a photo of the house and garden with Exterior Redesign.