Fence Calculator

Work out how many posts, rails and pickets a wood or vinyl fence needs — for a single straight run or several runs separated by gates and driveways.

Formulas tested · engine v1.0.0Runs on your deviceHow we calculate

Measurement system

Changing system converts the numbers you’ve entered, so your project stays the same size.

A fence with a gap (e.g. a driveway) is two runs. Each run needs its own end post.

Usually set by the length of your rails or panels.

%
Your result—

Your estimate

—

Enter your measurements to see the quantity.

Posts, sections, rails and pickets for one or more fence runs.

Find suppliers near you

Take your fence numbers to a local supplier and ask for a quote. Each button opens a search in your map app.

Leave empty to search near you. Only added to the map search — YardCalio never sees it or your location.

Opens Google, Apple or Bing Maps in a new tab. YardCalio does not recommend or rank businesses and is not paid by them. What to ask a supplier →

How to use the fence calculator

  1. Measure the total length of fence and count how many separate runs it has (a fence interrupted by a driveway is two runs).
  2. Enter the post spacing — normally set by the rail or panel length.
  3. Enter rails per section and, for a picket fence, the picket width and the gap you want between them.

Fence formulas

Sections = Length ÷ Post spacing (round up)
Posts = Sections + 1 per run
Rails = Sections × Rails per section
Pickets = Length ÷ (Picket width + Gap)

Corners on a continuous run reuse a post, so they do not add posts — but corner and gate posts often need to be stronger.

Worked example

150 ft of picket fence in two runs (split by a driveway), 8 ft post spacing, 2 rails per section, 3.5 in pickets with 2 in gaps, 5% spare pickets.

  1. Sections = 150 ÷ 8 = 18.75 → 19
  2. Posts = 19 + 2 = 21
  3. Rails = 19 × 2 = 38
  4. Pickets = 1,800 in ÷ 5.5 in × 1.05 → 344

Fence planning tips

  • Confirm property lines and any local rules on fence height and placement before ordering.
  • Gates need their own posts, hinges and latches — add them to your list.
  • Use the Concrete Calculator (post-hole mode) to estimate concrete for setting posts.

Frequently asked questions

How many fence posts do I need?

Divide the fence length by the post spacing and round up to get sections; add one post for each separate run of fence.

How many pickets do I need per foot?

Divide 12 inches by the picket width plus the gap. 5.5 in pickets with 0.5 in gaps take 2 pickets per foot.

How much concrete per fence post?

It depends on the hole size and depth. Use the Concrete Calculator’s post-hole mode with your hole diameter and depth.

Sources & methodology

Unit conversions use exact legal definitions. Material densities are typical planning values that vary in practice — see the calculation methodology for every constant, rounding rule and test.

  1. NIST Special Publication 811 — Guide for the Use of the International System of Units (SI) — Exact definitions of the inch, foot, yard, acre, pound and US gallon used for every conversion.