Skip to content
Carpentry Calculators

Search calculators

Your measurements

Units

Centre to centre. Bays come out equal and no wider than this.

Post to post. Ignored if there are no gates.

2 for low fences, 3 for 5–6 ft privacy fences, 0 for prefab panels.

Actual width. Enter 0 for prefab panels.

0 for a solid privacy fence.

Applies to pickets.

Results update as you type. Lengths accept decimals or fractions (e.g. 7 3/4).

Results

Posts
—
Bays (panels)
—
Pickets to buy
—
Bay width
—
Rails
—
Pickets (exact)
—

Save to a project

Projects are saved in this browser on this device only. They aren't uploaded anywhere, and clearing your browser data deletes them.

Want your brand in front of people using the Fence Calculator? Sponsor this calculator

Worked example

A 100 ft fence with posts no more than 8 ft apart, one 4 ft gate, three rails per bay, 5 1/2 in pickets with 1/2 in gaps, and 10% waste:

  1. Fenced length: 100 − 4 = 96 ft, in 2 segments of 48 ft (one each side of the gate).
  2. Bays: 48 ÷ 8 = 6 per segment, so 12 bays of exactly 8 ft.
  3. Posts: 12 bays + 1 gate + 1 = 14 posts (the gate posts are included).
  4. Rails: 12 × 3 = 36 rails.
  5. Pickets: (1,200 + 0.5) ÷ 6 = 200.1, rounded up to 201. With 10% waste: 222 pickets.

How it works: the formula

  • Fenced length = total length − gates × gate width.
  • Segments = gates + 1. The gates split the fence into equal segments.
  • Bays per segment = ⌈segment ÷ max post spacing⌉. Bays come out equal and never wider than your spacing.
  • Posts = bays + segments = bays + gates + 1.
  • Rails = bays × rails per bay.
  • Pickets = ⌈(length + gap) ÷ (picket width + gap)⌉, then × (1 + waste). The gates are clad too.

Assumptions and limitations

  • A straight fence on level ground. Corners and changes of direction need an extra corner post each.
  • Gates are assumed spread evenly along the run. If yours are at one end, the bay sizes change but the counts are usually the same.
  • Post depth, footings, concrete, gate hardware and fixings aren't included. Use the Post Hole Calculator for concrete.
  • Check local rules on fence height, boundaries and permits before you build.

Tools for this job

We may earn a commission if you buy through these links, at no extra cost to you. As an Amazon Associate we earn from qualifying purchases. Read our affiliate disclosure

Frequently asked questions

How many fence posts do I need?

Divide the fence length by the post spacing, round up to get the number of bays, and add one. A 100 ft fence with posts no more than 8 ft apart needs 13 bays and 14 posts. Each gate splits the run, so it adds one more post.

How far apart should fence posts be?

Most wood fences use posts 6 to 8 ft (1.8 to 2.4 m) apart. Prefabricated panels set the spacing for you. Closer posts make a stiffer fence and suit windy sites and tall privacy fences.

How many pickets do I need?

Divide the fence length by the picket width plus the gap between pickets. For 5 1/2 in pickets with 1/2 in gaps, each picket covers 6 in, so 100 ft (1,200 in) needs about 201 pickets. Add about 10% for splits and offcuts.

How many rails does each section need?

Two rails suit fences up to about 4 ft high. Three rails are typical for 5 to 6 ft privacy fences, so the boards don’t warp in the middle.