How the fence calculator works
A wood fence is a series of identical sections: two posts, two or three horizontal rails between them, and boards or pickets nailed to the rails. The calculator divides the fence length by the post spacing to find the number of sections, then counts the materials each section needs.
- Posts: one per section plus one to close the run, plus one extra for each gate so the gate has its own hinge and latch posts. Corners are not counted automatically; add one post per corner.
- Rails: 2 per section for fences 5 ft and under, 3 per section for 6 and 8 ft fences.
- Boards: the fence length in inches divided by board width plus gap, plus 5% for split, warped or knotted boards you'll reject. Gates are covered with the same boards, so gate width isn't subtracted.
- Concrete: bags per post × posts. Two 50 lb bags suit a 4×4 post in an 8–10 in hole about 2 ft deep; use 3 for deeper holes or gate posts.
The formula
posts = sections + 1 + gates
rails = sections × (2 if height ≤ 5 ft, otherwise 3)
boards = fence length × 12 ÷ (board width + gap) × 1.05, rounded up
concrete bags = posts × bags per post
Example: 100 ft of 6 ft privacy fence
Posts 8 ft apart, one gate, 1×6 boards (5.5 in actual) butted tight, 2 bags of concrete per post. Prices: $16 per post, $6 per 2×4 rail, $3.50 per board, $6.50 per bag.
| Item | Count | Cost |
|---|---|---|
| Sections (100 ÷ 8 = 12.5) | 13 | — |
| Posts (13 + 1 + 1 gate) | 15 | $240.00 |
| Rails (13 × 3) | 39 | $234.00 |
| Boards (1,200 ÷ 5.5 = 218.2, + 5%) | 230 | $805.00 |
| Concrete (15 × 2) | 30 bags | $195.00 |
| Total materials | $1,474.00 |
Switch to a 4 ft picket fence with 3.5 in pickets and 2.5 in gaps and the same 100 ft needs 210 pickets and only 2 rails per section. Posts should be at least 8 ft long for the 6 ft fence (6 ft plus 2 ft in the ground).
Tips before you dig
- Call 811 first. It's free, and required in most states, to have buried utility lines marked a few days before you dig post holes.
- Check the rules. Many towns and HOAs limit fence height (often 4 ft in front yards and 6 ft in back), require a permit and set how far from the property line the fence must sit.
- Use ground-contact posts. Buy posts rated for ground contact (UC4A or better). Crown the concrete at the top so water runs away from the post.
- Set the end and gate posts first, run a string line between them, and set line posts to the string.
- Leave a gap at the bottom. Keep boards about 2 in above the soil so they don't wick moisture and rot.
- Plan for fasteners. Use exterior-rated nails or screws: about 4 per board on a 2-rail fence and 6 on a 3-rail fence.
Frequently asked questions
How far apart should fence posts be?
8 feet on center is standard for wood privacy and picket fences because rails come in 8 foot lengths. In windy areas, for tall 8 foot fences or heavy boards, 6 feet gives a stiffer fence. Never exceed the length of your rails, and check local wind-load rules.
How many bags of concrete per fence post?
Typically 2 bags of 50 lb concrete for a 4x4 post in an 8 to 10 inch hole about 2 feet deep, and 3 bags for a deeper 3 foot hole or a gate post. Wider or deeper holes need more. Buying a few extra bags is cheap insurance, since unopened bags can usually be returned.
How deep should fence posts be?
A common rule is to bury at least one third of the post's height above ground, and at least 2 feet. A 6 foot fence usually needs posts set 2 to 3 feet deep, so 8 to 9 foot posts. In cold climates, set posts below the frost line so they are not heaved out in winter.
How many pickets do I need for 100 feet of fence?
For a privacy fence with 5.5 inch wide boards butted together, 100 feet needs about 219 boards, or 230 with 5 percent spare. A picket fence with 3.5 inch pickets and 2.5 inch gaps needs 200 pickets, or 210 with spare.
Do I need 2 or 3 rails on a fence?
Fences up to about 5 feet tall usually use 2 rails, one near the top and one near the bottom. Fences 6 feet and taller need a third rail in the middle to keep boards from warping. Very tall or heavy fences may use 4.
Does this include gate hardware?
No. Gates need hinges, a latch and often a drop rod or anti-sag kit, which typically cost 30 to 100 dollars per gate. The calculator adds one extra post for each gate but prices only posts, rails, boards and concrete.
Rates and figures last checked September 2026.
This calculator gives estimates for planning. Check current rates and product labels before you buy, list or file.