Home
Fence Calculator
Enter the fence length, post spacing, height, gate count, and the fence type. The calculator returns the number of posts, sections, panels or pickets, rails, and an optional concrete bag estimate.
Fence type
Total run of fence to build. · e.g. 100
Center to center between posts. · e.g. 8
Affects panel and picket lengths, not section counts. · e.g. 6
3 rails common on taller or heavier panel fences. · e.g. 2
Each gate opens the fence run and adds gate posts. · e.g. 1
e.g. 4
Most prefab panels are 6 or 8 ft wide. · e.g. 8
Most 60 lb fast-setting bags use 2 per post. · e.g. 2
Corners, gates, slopes, and property lines often add posts and adjust section layout. Check local code requirements before building.
96 ft of fence in 12 sections
14 posts
12 panels, 24 rails
Examples
100 ft panel fence, 8 ft spacing, 1 gate at 4 ft
12 sections, 14 posts, 12 panels, 24 rails
60 ft picket fence, 8 ft spacing, no gates, 5.5 in picket, 0.25 in gap
8 sections, 9 posts, ≈ 126 pickets, 16 rails
200 ft privacy fence, 6 ft spacing, 2 gates at 4 ft each
32 sections, 35 posts (3 with gates), 64 rails
How it works
Subtract the total gate openings from the fence length to get the effective length. Divide that by post spacing and round up for the section count. Posts equal sections plus one, plus one more for each gate. Panels are effective length divided by panel width; pickets are effective length in inches divided by picket width plus gap. Rails are sections times rails per section.
Sections · ⌈(length − gates) ÷ post spacing⌉
Posts · sections + 1 + gates
Panels · ⌈effective length ÷ panel width⌉
Pickets · ⌈(effective length × 12) ÷ (picket width + gap)⌉
Defaults: panel = 8 ft · picket = 5.5 in · gap = 0.25 in · rails per section = 2. Concrete per post is optional.
Related home measurement calculators
- Deck board calculator for the boards needed on a wood deck.
- Board foot calculator for lumber estimates by thickness, width, and length.
- Concrete calculator for slab pours next to fence work.
- Gravel calculator for drainage gravel under post holes.
- Stair calculator for landings or steps at gates.
- Square footage calculator for area math on yards or zones inside the fence.
- All home calculators.
Frequently asked questions
Divide the effective fence length (total length minus any gate openings) by post spacing and round up to get the number of sections. Posts equal sections plus one for the start of the run, plus an extra post for each gate opening (each gate needs its own post at each side). Corners, slope changes, and irregular property lines may add more posts in practice.
Six to eight feet is standard for most residential fences. Six-foot spacing is sturdier for tall privacy fences and windy sites. Eight-foot spacing uses fewer posts and works well with 8 ft prefab panels. Local code may set a maximum.
Two rails (one near the top, one near the bottom) is the common minimum for a 4 to 6 ft fence. Use three rails for taller fences (over 6 ft) or for heavier panels. The calculator multiplies rails per section by the section count to estimate the rail order.
Panel mode uses a prefab panel width (commonly 6 or 8 ft) and counts how many panels span the run. Picket mode uses a picket width plus a gap to count individual pickets. Choose panel for a fast prefab install and picket for a built-on-site board fence with custom spacing.
A common rule of thumb is two 60 lb bags of fast-setting concrete per post hole for a 6 ft wood fence on standard 4×4 posts. Heavier fences, taller fences, sandy soil, or corner posts may need three or more bags per hole. Enter your bag count per post in the optional concrete field and the calculator multiplies it by total posts.
Yes, partially. Gate count and gate width subtract from the effective fence length, which lowers the section count, and each gate adds an extra post to the post total to support the gate hardware. The calculator does not estimate gate hardware (hinges, latch, drop rod) or specialized gate posts. Order those separately.
Related calculators
Home
Concrete Calculator
Estimate the cubic yards and number of bags of concrete you need for slabs, footings, and columns.
Home
Gravel Calculator
Estimate cubic yards and tons of gravel needed to cover an area at any depth.
Home
Cubic Feet Calculator
Calculate volume in cubic feet from any length, width, and height — supports feet, inches, yards, centimeters, and meters.