1. Home
  2. Calculators
  3. Fence Calculator

Fence Calculator

For homeowners and builders pricing a fence before they go to the yard.

Free, no sign-up. Runs in your browser: nothing is uploaded.

Free workspace included. Docs, spreadsheets, notes and tasks that save on your device. No sign-up.Take a look

How to use Fence Calculator

  1. Enter your numbers, or press a sample to see an example.
  2. Read the results and the table under them.
  3. Copy the results or download the table.

Features

  • Posts, rails and pickets
  • Gates counted with their own posts
  • Open run or closed loop
  • Feet or meters
  • Optional price per item

Supported formats

Input

  • Typed lengths and prices

You get

  • On-screen results
  • Copyable text
  • CSV table

Private by design

Everything you enter is processed by your browser on this device. Nothing is sent to openWorkstand or anyone else, so the Fence Calculator is safe for private and work data. After you have used it once while online, it also works without an internet connection. How local processing works

Good to know

  • It assumes straight runs with even post spacing and does not plan corners, slopes or concrete.
  • Check local rules for fence height, setbacks and permits.
  • Everything runs in your browser; nothing you type is sent anywhere.

Guide

Counting posts, rails and pickets for a fence, with gates and closed loops

A fence looks simple until you stand in the hardware store and need to know how many posts to buy. The count depends on the length, the post spacing, the number of gates and whether the fence closes a loop. This calculator works through those steps, shows the real spacing between posts, and adds up the cost of the parts you price.

Sections and posts

Subtract the gate openings from the total length, divide by the post spacing and round up. That gives the number of sections between posts. A straight, open run needs one more post than sections, because each section has a post at both ends and neighbouring sections share one. A closed loop, such as a fenced yard with no gate, needs exactly as many posts as sections, because the last section ends where the first began.

Gates

A gate is a gap in the fence with its own pair of posts. It cuts the line into separate runs, and each open run needs the extra end post. An open fence with g gates has g + 1 runs, a closed loop with g gates has g runs and no runs when g is zero. The result gives the total posts and splits them into line or end posts and gate posts, two for each gate, which matters because gate posts are usually heavier.

Rails and pickets

Rails are counted as the number of sections times the rails per section, two by default and three for a tall fence. Pickets are counted from the length without gates divided by the picket width plus the gap, rounded up. Picket width and gap are typed in inches for feet or in millimetres for metres. Set the width to 0 to leave pickets out when you are building a panel or wire fence.

Prices

Fill in the price of a post, a rail, a picket and a gate to get a material cost in the currency you choose. Leave the price boxes empty to skip it. The cost covers only those four parts, so concrete, fixings, stain and delivery need to be added.

Edge cases

The gates must not take up the whole length, or the page says so. The post spacing must be above zero, and up to ten gates are accepted. Spacing is the distance from post centre to post centre. The tool does not know about corner posts, which are treated as ordinary posts, so a rectangular yard counts correctly as a closed loop with its corners among the posts.

A worked example

A 120 ft fence with one 4 ft gate has 116 ft of fence to build. At 8 ft spacing that is 15 sections, with a real spacing of 7.7333 ft. The posts total 17, which is 15 line or end posts and 2 gate posts, and there are 30 rails and 232 pickets. A closed yard of 60 m with 2.4 m spacing needs 25 sections and 25 posts, 50 rails and 600 pickets of 90 mm with 10 mm gaps. For a priced job of 200 ft with two gates, there are 24 sections, 27 posts, 48 rails and 384 pickets, and at 14 per post, 9 per rail, 2.40 per picket and 85 per gate the material cost is 1,901.60.

Limits

The calculator assumes straight runs and even spacing. It does not plan sloping ground, post depth, concrete, gate hardware or the length of rails that are sold in fixed sizes. Local rules on fence height, how close to a boundary you can build and whether a permit is needed vary, so check them before you buy.

Checked against the current version of the Fence Calculator on .

Frequently asked questions

Why is the real post spacing shorter than the 8 feet I typed?

The number of sections is rounded up so that no gap is wider than your spacing, and the fence length is then divided equally between them. 116 feet in 15 sections is 7.7333 feet apart.

Do I need extra pickets for cuts?

Yes, the count is the minimum to cover the length, so buy a few more for end cuts and damaged boards. A common allowance is around five percent, but check the layout for your own fence.

How many posts for 120 feet with one 4 ft gate?

The fence to build is 116 ft, which makes 15 sections at 8 ft spacing or less, and 17 posts, two of them gate posts. The real spacing works out at 7.7333 ft.

Why do gates add posts?

A gate splits the fence into separate runs, and each run needs a post at both ends, so every gate adds two posts.

Keep working with the result

openWorkstand also includes a free workspace with documents, spreadsheets, tasks, projects and a calendar that save to a folder on your computer.