ConstructionCalculators

Fence Calculator

Choose the fence type and enter its length, height, gates and post spacing to get the posts, pickets or panels, rails, concrete and cost.

8 ft6 ft
Fence
ft
ft
ft
ft
in
in

Fence

$1,705

$17.05 a foot · 14 posts · 12 sections of 8 ft

Posts, 4x4 × 10 ft
$232
Pickets, 5.5 in
$492
Rails, 2x4 × 8 ft
$161
Fast-setting concrete, 50 lb
$669
Gates, 4 ft
$150
Post holes12 in wide, 6 bags a post
36 in deep

How Much Material for a Fence?

100 ft of 6 ft wood privacy fence with one 4 ft gate takes 14 posts, 216 pickets, 36 rails and 84 bags of fast-setting concrete: about $1,705, $17.05 a foot, in treated pine. The same 100 ft by type, materials and installed:

MaterialsInstalled
Wood privacy
$1,705
$2,905
Picket, 4 ft
$1,265
$2,465
Board on board
$1,815
$3,015
Wood panels
$2,011
$3,211
Vinyl
$3,318
$4,818
Chain link, 4 ft
$1,389
$2,389
Materials, Installed, in dollars

Each with one 4 ft gate. Vinyl costs the most in materials; a 4 ft picket or chain link fence the least.

How to Calculate Fence Materials

Split the run into equal sections no longer than the post spacing, then count each part per section:

Sections = (length − gates) ÷ post spacing, rounded up; posts = sections + 1 + gates(100 − 4) ÷ 8 = 12 sections; 12 + 1 + 1 = 14 postsPickets: 96 ÷ 5.5 = 17.5 → 18 a section × 12 = 216Rails: 3 a section × 12 = 36Concrete: 12 in hole, 36 in deep = 2.1 cu ft ÷ 0.375 → 6 bags a post
8 ft6 ft
One 8 ft section of 6 ft privacy fence: 18 pickets of 5½ in on three rails between two posts

Measure along the line where the posts will go, and count each gate and corner. A corner adds no post of its own if it falls on a post; otherwise split the run into two straight runs and add them.

Posts, Pickets and Rails by Fence Length

FencePostsPicketsRails
50 ft811221
100 ft1422139
150 ft2034257
200 ft2645075
300 ft39684114

6 ft wood privacy fence, posts 8 ft apart, 5½ inch pickets, three rails a section, no gates.

How Many Fence Posts Do I Need?

Count the sections, add one post to close the run, then add one for every gate. A straight 100 ft run with posts 8 ft apart has 13 sections on 14 posts. Put a 4 ft gate in it and the fence drops to 12 sections, yet the post count stays at 14, because the gate brings a post of its own.

Ready-made panels work the same way: a straight line of panels needs one post more than it has panels, so 8 panels hang on 9 posts and 10 panels on 11. A 200 ft run with one gate comes to 25 sections and 27 posts.

For pasture and property lines it is easier to count by the mile. Posts for straight runs with no gates:

RunPosts, 8 ftPosts, 10 ft
1 mile661529
Half mile331265
Quarter mile166133

In metric, with posts 2.4 m apart, a straight 100 m run takes 42 sections and 43 posts; switch the calculator to Metric and it counts in meters.

Fencing a Yard With Corners

Count each straight run on its own and let the runs share their corner posts. Entering the whole perimeter as one line miscounts, because every run ends in a section of its own. A yard 75 ft deep and 50 ft wide, fenced down both sides and across the back, with a 4 ft gate at the house:

75 ft50 ft10 sections of 7.5 ft7 of 7.1 ft9 of 7.9 ft12345
  1. 1House wall: the fence starts and ends at it
  2. 2End posts at the house; one is the gate latch post
  3. 3Corner posts, shared by two runs
  4. 4Line posts, no more than 8 ft apart
  5. 5Gate post and the 4 ft gate

The three runs come to 26 sections, 28 posts, 444 pickets and 78 rails. Typed in as a single 200 ft line with one gate, the same fence would show 25 sections, 27 posts, 450 pickets and 75 rails: one post and three rails short. Run each side through the calculator, add up the posts, and take away one for every corner two runs share.

How to Measure for a Fence

  1. 1Find the property line on your survey or plat. If the corner pins can't be found, a licensed surveyor can stake them.
  2. 2Check the zoning setbacks from the line, the street and any easement before you mark the fence.
  3. 3Drive a stake at every corner and gate post and pull a string between them at post height.
  4. 4Measure each straight run along the string, where the posts will stand, not along a curb, a hedge or the house wall.
  5. 5Write down each gate's width and which run it sits in, and enter every run separately.

For a first figure before you go out with a tape, the distance tool on an online map measures the runs from above; check them on the ground before you order. Once the length is known, the face of the fence is the length times the height: 600 sq ft a side for 100 ft of 6 ft fence, which is what you stain or paint.

Fence Posts: Spacing, Depth and Concrete

  • Spacing: 8 ft for wood, matching standard panels; 6 or 8 ft for vinyl; no more than 10 ft for chain link line posts.
  • Depth: 1/3 to 1/2 of the height above ground, plus 6 in of gravel, by Quikrete; 3 ft for a 6 ft fence at half, so a 10 ft post.
  • Hole: three times the post's width, 12 in for a 4x4; chain link posts four times their diameter.
  • Concrete: 6 bags of 50 lb fast-setting mix for a 4x4 set 36 in deep, 4 at 24 in.
  • Corners and gates: chain link needs a heavier terminal post at every end, gate and turn of 30° or more, braced and trussed once the fence is 6 ft or taller.

The hole and the concrete change with the fence type. Per post and for 100 ft with one gate:

FenceHoleBags a postBags, 100 ft
Wood privacy12 in684
Picket, 4 ft12 in456
Vinyl15 in9126
Chain link, 4 ft9.5 in448

Vinyl takes the most concrete: its 5 in posts sit in 15 in holes, 9 bags each, so 126 bags for the run. Chain link takes the least, 48 bags, because its round posts are slim and stand 10 ft apart. For one post at any depth, size the hole to the frost line, and the Post Hole Concrete Calculator counts the bags by hole size.

How Much Fence for an Acre

For a lot fenced all the way around, the fence is the perimeter. A square acre is 43,560 square feet with sides of 208.7 ft, so it takes about 835 ft of fence. Fence and posts for square lots, with no gates:

LotFencePosts, 8 ft
0.25 acre417 ft53
0.5 acre590 ft74
1 acre835 ft105
2 acres1,181 ft148
5 acres1,867 ft234
10 acres2,640 ft330

A closed loop has as many posts as sections; add a post for each gate. A rectangle twice as long as it is wide needs about 6% more fence than a square of the same area. For a lot of another shape, add up its sides from the plat or survey, or find the area first with the Acreage Calculator.

Fencing a Slope

Measure a fence on a slope along the level, not along the ground: posts are spaced by horizontal distance. On a 10% grade the ground drops 10 in over each 8 ft section, and on a 20% grade 19 in.

  • Stepped: each section stays level and steps down at the post, leaving a triangle of open space under the low end. The posts on the downhill side of each step need to be longer by the step.
  • Racked: the rails follow the slope and the pickets stay plumb, so the bottom follows the ground. Wood pickets rack easily; ready-made panels only as far as their maker allows.

The number of posts, pickets and rails stays the same as on flat ground; on a steep slope add a little to the post length and the pickets for the steps.

Nails, Screws and Hardware

At two fasteners per picket at each of the three rails, the default 100 ft fence takes 1,296 nails or screws for the pickets, plus 72 rail ends to fasten to the posts, with a bracket or toe-nails at each. The IRC requires hot-dipped galvanized, stainless steel, silicon bronze or copper fasteners in preservative-treated wood. Add a hinge set and latch for each gate, and post caps if you want them.

Fence Types

  • Wood privacy: pickets butted edge to edge on three rails; our wood fence calculator counts them.
  • Board on board: two layers of pickets overlapping, private from both sides; see the Board on Board Fence Calculator.
  • Picket: narrow pickets with gaps, usually 3 to 4 ft high; count the pickets for any width and gap.
  • Vinyl: ready-made panels between hollow posts; count the vinyl panels and posts.
  • Chain link: fabric in 50 ft rolls on line and terminal posts with a top rail; figure the fabric and posts.

How to Build a Fence

  1. 1Check the property line and local rules, and call 811 a few days before digging.
  2. 2Stake the corners and gate posts and stretch a string line between them.
  3. 3Dig the end and corner holes first, set those posts plumb, then the line posts between.
  4. 4Fasten the rails between the posts, then the pickets or panels, keeping them off the ground.
  5. 5Hang the gates last, on posts that have had time to set.

The IRC exempts fences up to 7 ft high from a building permit; local zoning still sets heights, setbacks and pool fence rules. Price the job with installation, and the finish in the Fence Stain Calculator.

Frequently Asked Questions

How many fence posts do I need?

One more than the number of sections, plus one for each gate. 100 ft of fence with a 4 ft gate and posts 8 ft apart has 96 ft of fence in 12 sections: 14 posts.

How many fence posts for 200 feet?

27 posts 8 ft apart with one 4 ft gate: 196 ft of fence in 25 sections, one post to close the run and one for the gate. With no gate, 26.

How many fence panels do I need for 100 feet?

12 panels 8 ft wide on 14 posts with a 4 ft gate, or 13 panels on 14 posts with no gate. A panel cut short to finish the run still counts as a whole panel.

How far apart should fence posts be?

About 8 ft for wood privacy fences, the width of a standard 6 × 8 ft panel, and 6 or 8 ft for vinyl, to match the panels. Chain link line posts go no more than 10 ft apart, by Master Halco's specification.

How deep should fence posts be?

Quikrete's guidance is 1/3 to 1/2 of the post's height above ground, plus 6 inches of gravel under it; the calculator uses half, 3 ft for a 6 ft fence, in a hole three times the post's width. Posts that carry a structure go below the frost line.

How many bags of concrete per fence post?

A 4x4 set 36 inches deep in a 12 inch hole takes about 2.1 cubic feet: 6 bags of 50 lb fast-setting concrete at 0.375 cubic feet a bag. At 24 inches deep it is 4.

How many rails on a 6 foot fence?

Three: one near the top, one near the bottom and one in the middle of each section; a fence up to about 4 ft gets two. The calculator counts 2x4 rails 8 ft long.

How much does it cost to build a fence?

About $1,705 in materials for 100 ft of 6 ft wood privacy fence with a gate, $17 a foot, and about $2,905 with installation at $12 a foot.

How much fence do I need for an acre?

About 835 ft around a square acre, 43,560 square feet with sides of 208.7 ft. Half an acre takes about 590 ft and 5 acres 1,867 ft; a long, narrow lot takes more.

How many fence posts per mile?

661 posts 8 ft apart or 529 posts 10 ft apart for a straight mile of 5,280 ft with no gates. Corners and gates can add more.

Sources

  • International Code Council. (2020). 2021 International residential code (Sections R105.2 and R317.3).
  • Master Halco. (2017). Section 32 31 13 Chain link fence [Guide specification].
  • Merchants Metals. (2014). Section 32 31 13 Galvanized chain link fence and gates [Guide specification].
  • National Institute of Standards and Technology. (2010). Voluntary product standard PS 20-10: American softwood lumber standard.
  • Pipeline and Hazardous Materials Safety Administration. (n.d.). Call before you dig. U.S. Department of Transportation.
  • QUIKRETE. (n.d.). Setting posts without mixing.
  • QUIKRETE. (2025). QUIKRETE Fast-Setting Concrete Mix No. 1004 [Data sheet].

Updated .

Cite this page as:

Daniel, P. Fence Calculator. Available at: https://constructioncalculators.com/fence-calculator/. Accessed: October 28, 2026.