Skip to main content

DigitalCalculators.net

Fence Calculator

Work out the posts, rails and pickets you need for a wood fence, including gates, from the fence length and post spacing.

Results

ItemValue
Estimates for a straight run. Corners and ends may need extra posts, and gates often need sturdier posts. Check local rules, HOA rules and property lines, and call 811 before digging post holes.

Quick Answer

Divide the fence length by the post spacing and round up to get the sections, then add 1 for the posts. A 150 ft fence with 8 ft spacing and one 4 ft gate has 19 sections, 21 posts and 38 rails. With 5.5 in pickets and 0.5 in gaps, you need about 292 pickets.

Last updated: 2 November 2026 ·How we calculate this: length divided by post spacing and picket width

Table of Contents

How This Fence Calculator Works

Enter the total length of fence, the distance between posts and the picket size. The calculator takes off the gate openings, splits the rest into sections, and counts posts, rails and pickets. Each gate adds one extra post.

Quick explanation: posts = sections + 1 + gates, and pickets = fenced inches ÷ (picket width + gap).

  • Post spacing: 6 to 8 ft is common for wood fences.
  • Rails: 2 for shorter fences, 3 for 6 ft privacy fences.
  • Gap: use 0 for a solid privacy fence.

How to Use the Fence Calculator

  1. Measure the total fence length along the line, in feet.
  2. Choose the post spacing and number of rails per section.
  3. Enter the picket width and the gap you want between pickets.
  4. Enter the number of gates and their width.
  5. Press Calculate to see posts, rails, pickets and the picket cost.

Core Formulas

  • Fenced length: total length − (gates × gate width)
  • Sections: fenced length ÷ post spacing, rounded up
  • Posts: sections + 1 + number of gates
  • Rails: sections × rails per section
  • Pickets: fenced length × 12 ÷ (picket width + gap), rounded up

Key Terms

  • Post: an upright set in the ground that holds the fence up.
  • Rail: a horizontal board between posts that the pickets attach to.
  • Picket: an upright board that forms the face of the fence.
  • Section: the part of a fence between two posts.

Worked Example

A 96 ft privacy fence, posts every 6 ft, 3 rails, 3.5 in pickets with 0.5 in gaps, no gates.

  • Sections = 96 ÷ 6 = 16
  • Posts = 16 + 1 = 17
  • Rails = 16 × 3 = 48
  • Pickets = 96 × 12 ÷ 4 = 288

Real-Life Examples

  • A backyard: 200 ft with 8 ft spacing and two 4 ft gates needs 27 posts and about 384 pickets of 5.5 in with 0.5 in gaps.
  • A dog run: 60 ft with 6 ft spacing and one 4 ft gate needs 12 posts and 20 rails.
  • A garden border: 40 ft with 8 ft spacing and no gate needs 6 posts and 10 rails.

Privacy Fence vs Picket Fence

  • Privacy fence: usually 6 ft tall, with little or no gap, so it needs more pickets and often 3 rails.
  • Picket fence: usually 3 to 4 ft tall, with gaps, so it uses fewer pickets and often 2 rails.
  • Cost: privacy fences use more wood per foot.
  • Rules: front-yard fences often have lower height limits.

Posts and Pickets by Fence Length

No gates.

LengthPosts (8 ft)Rails (2 per section)Pickets (5.5 in + 0.5 in gap)
24 ft4648
48 ft71296
80 ft1120160
100 ft1426200
150 ft2038300
200 ft2650400
300 ft3976600

Before You Build

  • Call 811: have underground lines marked before digging post holes.
  • Property line: confirm where it is, and check local height limits.
  • Post depth: a common guide is about one third of the post length in the ground, below the frost line in cold areas.
  • Extra material: buy a few more pickets for damaged or warped boards.

Common Mistakes to Avoid

  • Forgetting gate posts. Each gate needs a strong post on both sides.
  • Ignoring corners. Each change of direction needs a post.
  • Using too wide a spacing. More than 8 ft can let rails sag.
  • No spare pickets. Some boards will split or warp.
  • Skipping the utility check. Always call 811 before digging.

Frequently Asked Questions

Divide the length by the post spacing, round up, add 1, and add 1 for each gate.

6 to 8 ft is common for wood fences. Closer spacing makes a stronger fence.

With 5.5 in pickets and 0.5 in gaps, about 200.

A common guide is about one third of the post length, and below the frost line where the ground freezes.

Two per section for fences up to about 4 ft, and three for 6 ft fences.

It depends on where you live. Many areas have height and placement rules, so check with your local office.

Many local rules and neighbors expect the finished side to face out. Check your local rules or HOA.

It depends on hole size and depth. Our Concrete Calculator can work it out from the hole size.

Cedar and pressure-treated pine are common. Cedar resists rot naturally, and treated pine is usually cheaper.

About 3 to 4 ft for people, and 10 to 12 ft or more for vehicles.

References & Sources

SourceUsed ForLink
811 Before You Dig Free utility locating before you dig. https://811beforeyoudig.com/
Wikipedia, Picket fence Fence parts and styles. https://en.wikipedia.org/wiki/Picket_fence