Wood & Trim

Fence Calculator

Count bays, posts, rails and vertical boards for one ungated run or closed loop.

Units

Your measurements

Results update as you type.

Example shown — use your own measurements.

Extra options & cost (optional)

Applied once. Choose an allowance for your project; zero adds no extra material.

Fractions and number formats

Use decimals (12.5), fractions (12 1/2 or 12-1/2), or explicit lengths (12ft 6in, 12′ 6″, 25 mm). A comma followed by one or two digits is a decimal comma: 12,5 = 12.5. Grouped commas mean thousands: 1,200 = 1200. Use a decimal point for ambiguous values. Scientific notation is not accepted.

Enter your measurements

Results update as you type.

About this calculator

Count bays, posts, rails and vertical boards for one ungated run or closed loop. Enter your measurements and check the worked example below. Product quantities use the label information you supply.

How to measure

  • Measure the actual usable surface or internal space, using the field labels for the selected mode.
  • Keep openings and excluded areas separate so they are subtracted once.
  • Recheck units and label coverage before ordering.

How to use this calculator

  1. Measure one ungated run and choose open run or closed loop.
  2. Enter the specified maximum bay spacing and rails per bay.
  3. Enter actual vertical-board face width and the planned gap.
  4. Read posts, full rail pieces and boards separately; deduplicate shared endpoints on your overall plan.

Formula

Bays = ceiling(run / maximum spacing); posts = bays + 1 for open runs, bays for closed loops

Rails = bays × rails per bay, with one full rail piece per bay per level

Open-run boards = ceiling((length + gap) / (board width + gap)); closed-loop boards = ceiling(length / pitch); apply extra once

Assumptions

  • The model covers one ungated run or closed loop with even bays.
  • Rails are counted as one full piece per bay per level; supported joints and offcut reuse are not designed.
  • Board gaps occur between boards; extra material applies once to the board count. Shared endpoints need manual deduplication.

Common mistakes

  • Applying the same allowance in both measurements and the extra-material field.
  • Entering coverage or yield from a different product or measurement basis.
  • Treating a quantity estimate as an installation or structural approval.

Worked example

Try it: press “Load example” above the form.

A 30 m open run with 2.5 m maximum bays has 12 bays and 13 posts. Two rails per bay need 24 rail pieces; 100 mm boards with no gap need 300 boards.

Limitations

Estimate each ungated run separately. Gate posts, hardware, corners, shared endpoints, horizontal-board layouts and rail joining are not included. Deduplicate shared posts on your plan. Wind, footing depth, spans and structural suitability require separate design.

Frequently asked questions

How are posts and rails counted?

The run is divided into whole evenly spaced bays. An open run has one more post than bays; a closed loop shares its start/end post. Rails are full pieces per bay per level, without a rail-joining design.

What does the worked example show?

A 30 m open run with 2.5 m maximum bays has 12 bays and 13 posts. Two rails per bay need 24 rail pieces; 100 mm boards with no gap need 300 boards.

Are gates, shared corners and supported joints included?

No. Estimate ungated runs separately, deduplicate shared endpoint posts on the full plan, and add gates and hardware separately. Rails are counted as full pieces per bay; joining and supports need a project design.

What does this fence quantity model exclude?

Estimate each ungated run separately. Gate posts, hardware, corners, shared endpoints, horizontal-board layouts and rail joining are not included. Deduplicate shared posts on your plan. Wind, footing depth, spans and structural suitability require separate design.

Reviewed by Codex AI editorial agent (Editorial, 2026-11-12).

Sources

Sources explain the methods and any named product presets. Check your product label where coverage, yield or density differs.

  • NIST: Revised Unit Conversion Factors
  • Defined geometric and purchase-quantity model

    Formulae on this page define the arithmetic model. Worked examples are illustrative, not product or installation recommendations.

Calculation documentation · Updated 2026-11-11 · Version 1.6.4. Estimates are planning aids. Confirm quantities, coverage and prices with your supplier before purchasing. Found an error? Report it.

Related calculators

All Wood & Trim calculators