Fence Calculator
Calculate how many fence posts, rails, pickets and bags of concrete you need for a wood privacy or picket fence based on its total length and post spacing.
By CalcBuilt Editorial TeamUpdated September 10, 2026Formulas checked against manufacturer specs, see how we calculate.
Results
- Fence posts
- 14 posts
- 12 sections of 8 ft, plus 1 for gates. Each post needs 8.5 ft, so buy 10 ft stock (4x4s come in 8, 10 and 12 ft)
- Rails
- 36 rails
- 3 per section, 8 ft long (2x4). Warning: 6 ft privacy fencing on 8 ft centers sags and racks in wind; use 2x6 top rails or 6 ft spacing
- Pickets
- 210 pickets
- 5.5 in wide with 0 in gap, 6 ft tall. Add 10% for culls; the yard will not take back split boards once the strap is cut
- Concrete
- 28 bags
- 2 x 50 lb (23 kg) bags per post, about 0.39 cu yd. Crown it above grade so water sheds away from the post
- Screws or nails
- 1,260
- 2 fasteners per picket per rail. Hot-dipped galvanized or polymer-coated for treated wood; electroplated screws rust out in a year
Fence formula
Sections = (Fence length - gate widths) / post spacing, rounded up
Posts = Sections + 1 + number of gates
Rails = Sections x rails per section
Pickets = Fence length (in) / (picket width + gap), rounded upWorked example
A 150 ft fence with two 4 ft gates, 8 ft spacing, 3 rails and 5.5 in pickets with no gap: 142 / 8 = 17.75, so 18 sections. Posts = 18 + 1 + 2 = 21. Rails = 18 x 3 = 54. Pickets = 142 x 12 / 5.5 = 310. Concrete at 2 bags per post = 42 bags.
Quick reference
| Fence type | Posts | Rails | Pickets |
|---|---|---|---|
| 4 ft picket, 1 x 4 with 2.5 in gap, 2 rails | 14 | 26 | 200 |
| 6 ft privacy, 1 x 6 no gap, 3 rails | 14 | 39 | 219 |
| 8 ft privacy, 1 x 6 no gap, 4 rails | 14 | 52 | 219 |
How to calculate fence materials
Divide the fence length by the post spacing and round up for the number of sections. Posts are sections plus one, plus an extra post for each gate. A 100 foot fence with 8 foot spacing has 13 sections and 14 posts, or 15 with one gate.
Pickets are the total fence length in inches divided by the width of one picket plus its gap. A 6 foot privacy fence uses about 18 pickets of 5.5 inches per 8 foot section with no gap (96 / 5.5 = 17.5). Rails are two per section up to 5 feet high and three for 6 feet and taller. 8 foot centers let you use 8 foot 2x4 rails uncut, but a 6 foot privacy fence on 8 foot centers with 4x4 posts sags and racks in wind; pros go 6 feet on center or run 2x6 top rails.
Post depth and concrete
Bury one third of the post length, at least 2 feet, and below the frost line where you have one. A 6 foot fence needs 8 feet 6 inches of post, so you buy 10 foot 4x4s because 9 foot is not a stock length. Gate posts go 6 inches deeper and get a third bag. Each hole takes two 50 lb bags of fast-setting concrete over 4 inches of gravel, crowned above grade so water runs off the post instead of pooling against it.
Waste on a fence is culls, not cuts. A bundle of 1x6 pickets has 5 to 10 percent that are split, waned or cupped, and the yard will not take them back once the strap is cut. Add 10 percent to pickets, and buy rails to the section count since 8 foot 2x4s are cut to fit between posts.
What this calculator leaves out
Call 811 before digging; the locate is free and a cut gas or fiber line is billed to you. Find the survey pins so the fence sits on your side of the line. Check setbacks, height limits (typically 6 feet in a rear yard and 4 feet in a front yard), the HOA and the permit. Most towns require the finished side to face out.
Not counted: gate frames and hardware, post caps, 4 inches of gravel per hole, and 2x4 kickers for the gate posts. Posts and any rail touching the ground need the ground-contact UC4B stamp, not the UC3B above-ground grade.
Mistakes that cost money
- Digging without calling 811: the locate is free, and a cut gas or fiber line is billed to you, often in the thousands.
- Building on the neighbor's side of the line means moving the fence; find the survey pins or pay for a survey first.
- A 4 ft gate on a 4x4 sags in a season; use a 6x6 or steel post, or a braced 4x4 set 3 ft deep.
- Above-ground-rated (UC3B) 4x4s rot at grade in 5 to 8 years; posts in the ground need the ground-contact UC4B stamp.
- Electroplated screws on treated pickets rust and streak within a year; use hot-dipped galvanized or polymer-coated fasteners.
- Wet pickets butted tight shrink 1/8 to 1/4 in and show daylight; use board-on-board or accept the gap.
Key facts
- Standard post spacing is 8 ft so rails can be cut from stock 8 ft or 16 ft lumber.
- A 6 ft privacy fence needs 3 rails per section; fences up to 5 ft tall need 2.
- A 6 ft fence needs 8 ft 6 in of post, so buy 10 ft 4x4s; posts are stocked in 8, 10 and 12 ft only, and 9 ft does not exist.
- An 8 ft section takes about 18 pickets of 1 x 6 (5.5 in) or 28 pickets of 1 x 4 (3.5 in) with no gap.
Frequently asked questions
Do I need a permit to build a fence?
Most towns require one for any fence over 4 to 6 feet and all will enforce setbacks, height limits and a finished-side-out rule. Check the HOA too, find the survey pins so the fence is on your property, and call 811 for a free utility locate before you dig.
How many pickets per 8 foot fence section?
About 18 pickets using 5.5 inch (1x6) boards with no gap, or 28 using 3.5 inch (1x4) boards.
How deep should fence posts be?
One third of the post length, at least 2 feet, and below the frost line in cold regions. A 10 foot post for a 6 foot fence goes about 3 feet in. Gate posts go 6 inches deeper.
How many bags of concrete per fence post?
Two 50 lb bags of fast-setting concrete per post for a 6 foot fence in a 10 inch wide, 2 foot deep hole. Use three bags for gate posts, 6x6 posts and deeper frost-line holes.
Sources and references
- QUIKRETE Fast-Setting Concrete Mix product page (50 lb bags for fence posts) (Quikrete)
- Setting Posts project guide: hole diameter and depth (Quikrete)
- Fences for the Farm, Circular 774: post spacing and depth (University of Georgia Extension)
Next steps for this project
The usual order for a framing, decks & fences project. See all framing, decks & fences calculators.
Embed this calculator
Results are estimates based on standard formulas and typical product specifications. Confirm quantities with your supplier and local code before ordering.