Auto/Utility

Fence Calculator

Estimate the posts and rails needed for a wood fence run.

Estimated fence needed: 14 posts for Fence Length 98 ft, the page's opening figures; on the metric page, 30 m gives 14 posts. Sources are cited below.

  • Answers as you type
  • 4 sources cited
  • Calculated in your browser
SettingsSettings for this calculationUS
Market
Imperial · sales tax
The total straight-line run of fence you're building.

For a fence with corners, measure and add up each straight section separately.

Tools needed: Tape measure, Stakes and string to mark the line

Closer spacing is sturdier but needs more posts and concrete.

8 ft is standard for most residential wood fences. Use 6 ft spacing for taller fences, high-wind areas, or heavier panel material.

Taller fences need more horizontal rails per section to resist wind and sagging.

Choose the range your fence height falls into.

How many times the fence line turns; each turn takes a post of its own.

The run is counted as if it were straight, with a post at each end. Every corner adds one post where the line changes direction, on top of the line posts; gates are entered below.

Each gate takes its width out of the fenced run and needs a post on each side.

A gate splits the run: the fence stops at a gate post, the gate hangs across the opening, and the fence starts again at the next gate post. So each gate adds one post to the count, and two of the posts are the gate's own, usually a size heavier than a line post. The gate leaf itself is not counted.

The clear opening of one gate, between its two posts.

A pedestrian gate is commonly 0.9 to 1.2 m (3 to 4 ft); a drive gate 3 to 3.6 m (10 to 12 ft). The width is taken out of the fence length before the bays and pickets are counted.

The face width of one picket or board; 0 leaves the pickets out (ready-made panels).

Dog-ear pickets are commonly 5.5 in (14 cm) wide, featheredge boards in the UK 100 to 150 mm. Enter 0 when the fence is made of prefabricated panels, which have their boards built in.

The space left between neighbouring pickets.

A privacy fence leaves little or none; a picket fence commonly 1 to 3 in (2.5 to 7.5 cm).

Extra rails and pickets for knotty rejects, splits and the narrow closer in each bay.

Applied to the rails and pickets to order, never to the posts. Five suits a clean straight run of graded stock; a fence of many short bays and corners wants ten.

The diameter of each post hole; 0 leaves the concrete out.

A common rule is about three times the post's width: a 10 in (250 mm) hole for a 4 in post, 12 in (300 mm) for a 6 in post. The hole size is yours to choose; the page only counts the concrete it holds.

The depth of concrete in each hole.

A rule of thumb is a third of the post's height above ground, and below the frost line where the ground freezes. Your local code or the fence maker's instructions decide it; the page does not.

The actual face of a square post, taken out of the hole's volume.

A 4×4 is 3.5 in (89 mm) actual, a 6×6 is 5.5 in (140 mm); a UK 100 mm post is 100 mm. The post's own volume in the hole holds no concrete.

Estimated fence needed

14 posts

High confidence
Fence length
98 ft
Sections
13 sections
Line and end posts
14 posts
Corner posts
0 posts
Section width, as set out
7.54 ft · 7 ft 6 7/16 in
Rails needed
39 rails
Rails to order, spare added
41 rails
Pickets before the spare
204.52 pickets
Pickets to order, spare added
215 pickets
Concrete per post hole
0.92 ft³
Concrete for all post holes
12.89 ft³
Post bags, 80 lb (30 kg metric)
22 bags

Formula with your numbers

  1. Divide the run into bays98 ft − gates × , ÷ , rounded up = 13 sections
  2. Add the closing, corner and gate posts13 sections + 1 + corners + gates = 14 posts
  3. Multiply the bays by the rails13 sections × the rails a fence takes = 39 rails, + % spare = 41 rails
Then change the inputs to see how far the answer moves.

Show calculation logic

How this was calculated

Formula source(s)

  • Post count = (fence length / post spacing) + 1; typical post spacing is 6-8 ft for wood fencing
  • Recommended rails: 2 for fences under 5 ft, 3 for 5-7 ft, 4 for 8 ft fences
  • Picket count = fenced length / (picket width + gap), the Fence Picket Calculator's rule; concrete per post hole = (π d² / 4 − post face²) × hole depth
  • Premix concrete yields about 0.0075 cubic feet per pound of dry mix (an 80 lb bag about 0.6 cubic feet), the Concrete Calculator's figure

Inputs used

Fence Length
98 ft
Post Spacing
8 ft (standard)
Fence Height
5-7 ft
Corners (changes of direction)
0
Gates
0
Gate Width (each)
3.5 ft
Picket Width
5.5 in
Gap Between Pickets
0.25 in
Spare Rails and Pickets (%)
5
Post Hole Diameter
10 in
Post Hole Depth
24 in
Post Size (square)
3.5 in

Intermediate steps

Fence length
98 ft
Sections
13 sections
Line and end posts
14 posts
Corner posts
0 posts
Section width, as set out
7.54 ft
Rails needed
39 rails
Rails to order, spare added
41 rails
Pickets before the spare
204.52 pickets
Pickets to order, spare added
215 pickets
Concrete per post hole
0.92 ft³
Concrete for all post holes
12.89 ft³
Post bags, 80 lb (30 kg metric)
22 bags
Final result14 posts

What this calculation does not cover

  • A part-bay at the end is rounded up to a whole section, so the count assumes every bay runs the full 6 or 8 ft you picked; the run is never redistributed into equal bays, and the last one comes out short unless you reset the spacing on site.
  • Rails are counted as one continuous piece per bay per course, so nothing is added for stock lengths that fall short of a post or for splices; the spare percentage covers rejects and off-cuts on the rails and pickets to order, never the posts.
  • The rail count steps in three fixed jumps, two then three then four, so a 5 ft fence and a 7 ft fence sharing a band come back with the same three rails, and no part of the arithmetic responds to wind exposure or panel weight even though the height and spacing hints both raise them.
  • Height feeds the rail count and nothing else: it never sizes the posts, so the extra length buried below grade is not counted, and the hole diameter and depth behind the concrete figure are yours. The concrete is the hole's cylinder less the post's square, with nothing added for a belled or ragged hole or for gravel at the bottom.
  • Pickets are counted over the fenced length as one run at the width and gap entered, as the Fence Picket Calculator does, so the narrow closer in each bay comes out of the spare percentage; prefabricated panels (enter 0 for the picket width), fasteners, post caps and end treatment against rot are counted nowhere.
  • Each gate takes its width out of the run and adds one post, so two of the posts are the gate's own; the gate leaf, its hinges and latch, and any heavier gate post size are left to you.
  • Both spacing choices are stored as the imperial 6 ft and 8 ft, so the metric labels of 1.8 m and 2.4 m are rounded restatements of those figures, and a bay of any other size — a 2.0 m panel, say — cannot be entered at all.

Estimated cost — your price

This site holds no price list for this material — local prices vary too much to publish honestly. Enter your supplier's price and the result is costed with it.

20 ft5 m98 ft29.87 m7.54 ft2.3 m

Part of bigger jobs

This trade is one line of a job takeoff. Run the whole job and every other trade comes back with it, off the same measurements.

Or plan the space itself: measure it once, doors and windows included, and this figure comes back worked out on that space, with what goes with it.

Computed in your browser — nothing you enter is uploaded. Presented in US customary units and US trade terminology. Where a formula follows a published standard, that standard and its edition are cited beside it on this page; where none governs, the page says so. Local amendments override model codes — verify against the code in force where you build.

Sources checked 2026-10-31 · 4 test vectors · v1.1.0

Regulatory standards & verification citations4
  1. Post count = (fence length / post spacing) + 1; typical post spacing is 6-8 ft for wood fencing
  2. Recommended rails: 2 for fences under 5 ft, 3 for 5-7 ft, 4 for 8 ft fences
  3. Picket count = fenced length / (picket width + gap), the Fence Picket Calculator's rule; concrete per post hole = (π d² / 4 − post face²) × hole depth
  4. Premix concrete yields about 0.0075 cubic feet per pound of dry mix (an 80 lb bag about 0.6 cubic feet), the Concrete Calculator's figure
Cite this page

Your workspace

Most jobs need more than one number. Add the calculators you need next and they open right here, underneath this one — your figures stay on screen and nothing is lost to a page change.

Tools and safety for this job

To set fence posts and fix fence panels or boards. Generic types, no brands, no prices.

Protection this work requires

  • Hardwood dust is a recognised carcinogen: extract at the tool and wear a P2/N95 respirator when cutting or sanding indoors.
  • Wet cement and lime burn skin and eyes painlessly until the damage is done: waterproof gloves to EN 374, safety glasses whenever the mix can splash, and never kneel in wet mix in permeable trousers.
  • Saws, grinders and breakers run above 85 dB, where hearing damage accumulates and does not recover: defenders or plugs for every cut, not just the long ones.
  • Boards, blocks and bagged material cause most lasting back injuries on small sites: two people or a lifter for full sheets, and never a bag on one shoulder up a ladder.
  • Digging blind strikes gas, water and power every day: get the plans, scan with a cable avoidance tool, and hand-dig trial holes over anything you find.
Show the 10 tools this job needs

Essential

  • Cable and pipe detector

  • Claw hammer

  • Cordless drill/driver

  • Mixing bucket or tub

  • Post hole digger or auger

  • Spirit level

  • String line and pins

  • Tape measure

Recommended

  • Circular saw

  • Post driver

Also needed as materials: circular saw blades, drill and driver bits.

what each landscaping tool is for, and the spec that decides which to buy where one does.

Draw the fence line

The run in elevation: the posts at equal bays, the rails, pickets and gates, and the concrete in each hole.

Now that you have the number

These guides cover the work this quantity is for — the first ones run this calculator inside the section that raises the question.

Already have some? How long a fence will my posts set out?

Worked example: Privacy fence — step 2 of 7

Already gone wrong? My fence posts are rotting or the fence is leaning

The data behind it: Production rates by operation

How to calculate fence in 3 steps

  1. Divide the run into baysTake each gate's width off the fence length, divide what is left by the post spacing and round up to whole sections.
  2. Add the closing, corner and gate postsA straight run has one post more than it has sections; add one post for every corner and one for every gate, since the fence stops at one gate post and starts again at the other.
  3. Multiply the bays by the railsMultiply the sections by two, three or four rails for the fence's height, then add the spare percentage for rejects and offcuts and round up.

Posts for common fence lengths

Page defaults, not your figures above.

Fence lengthEstimated fence needed
50 ft (15.24 m)8 posts
100 ft (30.48 m)14 posts
150 ft (45.72 m)20 posts
200 ft (60.96 m)26 posts
300 ft (91.44 m)39 posts
15 m (49.21 ft)8 posts
30 m (98.43 ft)14 posts
50 m (164.04 ft)22 posts
100 m (328.08 ft)43 posts

Key facts

  • A wood fence takes one post more than its sections: posts = fence length ÷ post spacing + 1, with 6 to 8 ft (1.8 to 2.4 m) the usual spacing for wood fencing. (Fence post-count rule)
  • Wood fence rails per bay: two for a fence under 5 ft (1.5 m), three for 5 to 7 ft (1.5 to 2.1 m), and four for an 8 ft (2.4 m) fence. (Fence rails by height)
  • Concrete in a fence post hole is the hole's cylinder less the post: (π × diameter² ÷ 4 − post face²) × hole depth. (Post-hole concrete formula)
  • An 80 lb bag of premix concrete yields about 0.6 cu ft (17 L), about 0.0075 cu ft of concrete per pound (0.47 L per kg) of dry mix. (Premix concrete yield (80 lb bag))

Frequently asked questions

Do I need a post at every corner?
Yes. Enter the number of corners and the page adds one post for each, on top of the line posts and the two end posts of the run.
How deep should fence posts be set?
A common rule of thumb is at least 1/3 of the post's above-ground height, set in concrete — check local frost-line depth requirements too, which can require deeper footings in cold climates.
Does this include gates?
The gate posts, yes. Enter the number of gates and their width: the width comes out of the fenced run and each gate adds one post, since the fence stops at one gate post and starts again at the other. The gate leaf, hinges and latch are not counted, and gate posts are usually a size heavier than line posts.
What does the 'Section width, as set out' figure mean?
It is the fence length divided by the number of sections counted. The post and rail counts are the same either way; this row shows the width each bay comes to if you share the run evenly between those posts on site, instead of leaving the short last bay the count assumes, and it is never wider than the spacing picked. Evenly shared bays suit a fence built in place from rails and boards; ready-made panels come in one width and cannot be shared out, so with panels the last bay takes a panel cut down to fit instead.
Do I need the rail count if I am putting up ready-made panels?
No. A prefabricated panel — the usual garden fence panel in the UK, or a pre-built privacy section in North America — has its rails built in, so only the post count applies, along with the clips or brackets the panels hang by, or the slotted concrete posts used for panel fencing in the UK. The rail figure is for a fence built in place: horizontal 2×4 rails fixed to the posts in North America, or the triangular arris rails morticed into the posts of a UK closeboard fence.
Which spacing should I pick for UK panels 6 ft wide?
The 1.8 m (6 ft) option, knowing the page takes it as the distance between post centres. A panel 1.83 m (6 ft) wide between posts 100 mm (4 in) square puts the centres about 1.93 m (6 ft 4 in) apart, so on a long run this page can count a post or more beyond what the panels need. Set the posts out from the panels actually bought and treat this count as the upper figure.
How do I measure a fence on sloping ground?
By how the bays will meet the slope. A stepped fence keeps each bay level and drops at the posts, so its bays are set out on the level: measure the horizontal length, and expect the post on the low side of every step to stand taller, which this count does not size. A fence that follows the ground, with its rails parallel to the slope (racked, in North American usage), is measured along the slope, since each rail runs that sloping length. A square-made panel can only be stepped; a fence built in place can go either way.
Preliminary estimate, not certified engineering. This tool produces an indicative quantity calculation for planning purposes only — it is not a certified structural analysis, a guaranteed material takeoff, or a substitute for building department approval. Always verify measurements on-site and have a licensed contractor or structural engineer review any load-bearing, code-sensitive, or safety-critical work before purchasing materials or starting construction. Spotted an arithmetic or standards error? Report it to contact@craftquantities.com with your inputs — a confirmed fix gets a permanent check of its own, so the same mistake cannot come back.