Rectangle Fence Perimeter Calculator that turns length and width, area, acreage or fence on hand into net fence run, posts by side, squaring diagonal, materials and installed cost.
Gates sit on the front length; set them and the fence type in the panels below.
Gates & House Wall
Fence Type, Cost & Concrete
Fence Plan Diagram
Side-by-Side Post Layout
| Fence Section | Length | Bays | Post Spacing | Pickets |
|---|---|---|---|---|
| Back Length | 60.00 ft | 8 | 7.50 ft | 131 pickets |
| Left Width | 40.00 ft | 5 | 8.00 ft | 88 pickets |
| Right Width | 40.00 ft | 5 | 8.00 ft | 88 pickets |
| Front, Section 1 | 28.00 ft | 4 | 7.00 ft | 62 pickets |
| Gate 1 | 4.00 ft opening | -- | 2 gate posts | -- |
| Front, Section 2 | 28.00 ft | 4 | 7.00 ft | 62 pickets |
| Net Fence Run | 196.00 ft | 26 | 27 posts | 431 pickets |
Fence Length by Acreage
| Lot Size | Area | Square | 2:1 Rectangle | Circle | Square Posts |
|---|---|---|---|---|---|
| Your Lot (0.055 acres) | 2,400 sq ft | 196 ft | 207.8 ft | 173.7 ft | 28 |
| 1/4 Acre | 10,890 sq ft | 417.4 ft | 442.7 ft | 369.9 ft | 56 |
| 1/2 Acre | 21,780 sq ft | 590.3 ft | 626.1 ft | 523.2 ft | 76 |
| 1 Acre | 43,560 sq ft | 834.8 ft | 885.5 ft | 739.9 ft | 108 |
| 2 Acres | 87,120 sq ft | 1,180.6 ft | 1,252.3 ft | 1,046.3 ft | 148 |
| 5 Acres | 217,800 sq ft | 1,866.8 ft | 1,980 ft | 1,654.4 ft | 236 |
| 10 Acres | 435,600 sq ft | 2,640 ft | 2,800.1 ft | 2,339.6 ft | 332 |
Step-by-Step Math
- Gross perimeter P = 2 × (L + W) = 2 × (60.00 ft + 40.00 ft) = 200.00 ft.
- Net fence run = P - gates = 200.00 ft - 1 × 4.00 ft = 196.00 ft.
- Corner diagonal d = √(L² + W²) = √((60.00 ft)² + (40.00 ft)²) = 72.11 ft.
- Posts = 6 corner, end and gate posts + 21 line posts (each section split into bays no wider than 8.00 ft) = 27 posts.
- Cost = 196.00 ft × $42.50/ft = $8,330.
- Fence to buy = 196 ft Net Fence Run (0.055 acres enclosed).
What the Rectangle Fence Perimeter Calculator Finds
A rectangular fence needs more than one perimeter number. You need the fence length after gates and open sides, the post count side by side, the diagonal that squares the corners, and the materials and cost for the fence type you plan to build.
The rectangle fence perimeter calculator works all of that from two sides, from an area and one side, from an acreage and a shape, or from a fence length you already have. It lays out each side and gate section on its own, so corner and gate posts land where they belong.
A 60 × 40 ft yard with one 4 ft gate has a 200 ft gross perimeter and a 196 ft net fence run. It needs 27 posts at no more than 8 ft apart, and both corner-to-corner diagonals should read 72 ft 1-5/16 in when the layout is square.
Perimeter of a Rectangle Fence Formula
The perimeter of a rectangle is twice the length plus twice the width, the core of every rectangle fence perimeter calculator formula. For a fence, subtract every gate opening, since the gate leaf replaces that stretch of fence.
P is the gross perimeter, L the length, W the width, n the number of gates, g the width of each gate and F the net fence run to buy. For the 60 × 40 ft yard, P = 2 × (60 + 40) = 200 ft and F = 200 - 1 × 4 = 196 ft, or 65.3 yd.
The same formula works in any unit, as long as both sides use it. A rectangle 12 cm long and 8 cm wide has a perimeter of 2 × (12 + 8) = 40 cm, and the answer always comes out in the same length unit as the sides.
A perimeter can never be negative, and the rectangle fence perimeter calculator rejects inputs that would make one. It is a sum of side lengths, and every side is a positive distance, so a negative result only means a gate or wall width was entered larger than the fence it sits on.
Perimeter from area and one side
If you know the enclosed area and one side, divide to find the other side first. Many rectangles share the same area, so one side is always needed.
A 3,000 sq ft yard with a 60 ft front is 50 ft deep, so its perimeter is 220 ft. With a 4 ft gate, the rectangle fence perimeter calculator gives a 216 ft net run and 31 posts at 8 ft maximum spacing.
Fences with an open side or a house wall
Not every fence closes all four sides, so the rectangle fence perimeter calculator handles three layouts beyond a full enclosure. A yard backed by a barn, a hedge or the house needs fence on only three sides, and the formula drops the side you skip.
| Layout | Gross Formula | 60 × 40 ft Gross | Net After 4 ft Gate | Posts at 8 ft |
|---|---|---|---|---|
| 4 sides, full enclosure | 2(L + W) | 200 ft | 196 ft | 27 |
| 3 sides, back length open | L + 2W | 140 ft | 136 ft | 20 |
| 3 sides, one end open | 2L + W | 160 ft | 156 ft | 23 |
| Back tied to a 30 ft house wall | 2(L + W) - wall | 170 ft | 166 ft | 24 |
Tying into a house adds two wall-end posts but removes the wall length from the run. The house case assumes the wall sits centered on the back line, with equal fence runs on each side.
How Many Fence Posts Do I Need?
Split each side into equal bays no wider than your maximum spacing, then add one post per bay plus the corner, end and gate posts. Counting per side matters because corners and gate openings fix where posts must stand.
Nside is the number of bays on a side or gate section of length S, and s is the maximum post spacing. Each section adds Nside - 1 line posts between its end posts.
Dividing the whole 200 ft perimeter by 8 ft suggests 25 posts. The 60 × 40 ft yard actually needs 27: four corners, two gate posts and 21 line posts, because the 4 ft gate splits the front into two 28 ft sections that each start and end on a post.
The rectangle fence perimeter calculator spaces each side evenly, so bays come out between 7.00 and 8.00 ft on this yard. Equal bays look cleaner, and order more evenly, than a row of full bays with one short leftover at the corner.
How many fence posts for 200 feet?
A straight 200 ft run at 8 ft spacing needs 26 posts: 25 bays plus one extra post to close the end. Fold that 200 ft into a 50 × 50 ft square and it takes 28 posts, since each of the four sides needs its own corner post layout.
Spacing changes with the fence type, and the rectangle fence perimeter calculator recounts posts for whatever spacing you set. Chain link specifications that follow ASTM F567 space line posts no more than 10 ft apart, so the same 50 × 50 ft square in chain link takes 20 posts.
Standard post spacing by fence type
Wood privacy and picket fences usually stay at 8 ft or less, which matches 8 ft rails. Vinyl and aluminum posts are spaced to the panel width. Barbed wire runs wider because line posts are driven, not set in concrete.
| Fence Type | Spacing Used | Posts, 60 × 40 ft | Main Material | 80 lb Concrete Bags |
|---|---|---|---|---|
| Wood privacy | 8 ft | 27 | 475 pickets, 78 rails | 54 |
| Wood picket | 8 ft | 27 | 437 pickets, 52 rails | 54 |
| Chain link | 10 ft | 21 | 5 rolls of 50 ft fabric | 63 |
| Vinyl panels | 8 ft | 27 | 26 panels | 54 |
| Aluminum panels | 6 ft | 35 | 34 panels | 70 |
| Barbed wire, 4 strands | 12 ft | 20 | 862 ft of wire, 1 spool | 12 |
Every row uses one 4 ft gate, 10% waste on pickets, fabric and wire, and 10 in by 30 in post holes. Barbed wire sets only corner, end and gate posts in concrete, so it needs 12 bags instead of 54.
Fence Length per Acre
A square uses the least fence of any rectangle for a given area. One acre fenced as a square needs 834.8 ft of fence, about 254.5 m, and stretching it to a 2:1 rectangle adds about 51 ft.
The rectangle fence perimeter calculator compares the same acreage as a square, a 2:1 rectangle and a circle. Square post counts assume 8 ft maximum spacing.
| Lot Size | Area | Square | 2:1 Rectangle | Circle | Posts, Square |
|---|---|---|---|---|---|
| 1/4 acre | 10,890 sq ft | 417.4 ft | 442.7 ft | 369.9 ft | 56 |
| 1/2 acre | 21,780 sq ft | 590.3 ft | 626.1 ft | 523.2 ft | 76 |
| 1 acre | 43,560 sq ft | 834.8 ft | 885.5 ft | 739.9 ft | 108 |
| 2 acres | 87,120 sq ft | 1,180.6 ft | 1,252.3 ft | 1,046.3 ft | 148 |
| 5 acres | 217,800 sq ft | 1,866.8 ft | 1,980.0 ft | 1,654.4 ft | 236 |
Run through the rectangle fence perimeter calculator, a 1/2 acre lot needs about 590 ft of fence if it is square and 626 ft if it is twice as long as it is wide. Long, narrow lots need much more: a 1/2 acre at 4:1 needs 738 ft.
Switched to metric, the rectangle fence perimeter calculator reports hectares and meters: one hectare fenced as a square is 100 × 100 m and needs 400 m of fence. That is the figure behind a fence meter calculator by acre or hectare.
How Much Is 200 Feet of Fencing?
Installed fence is priced per linear foot, so the rectangle fence perimeter calculator finds cost from the net run, not the gross perimeter. At $42.50 per foot, 200 ft of wood privacy fence costs $8,500, before gate hardware.
The table multiplies three common lengths by the per-foot price ranges the rectangle fence perimeter calculator uses for each type. Replace them with your contractor's rate for a real budget.
| Fence Type | Price per Foot | 120 ft | 200 ft | 300 ft |
|---|---|---|---|---|
| Wood privacy | $25 to $60 | $3,000 to $7,200 | $5,000 to $12,000 | $7,500 to $18,000 |
| Wood picket | $20 to $50 | $2,400 to $6,000 | $4,000 to $10,000 | $6,000 to $15,000 |
| Chain link | $9 to $30 | $1,080 to $3,600 | $1,800 to $6,000 | $2,700 to $9,000 |
| Vinyl | $30 to $60 | $3,600 to $7,200 | $6,000 to $12,000 | $9,000 to $18,000 |
| Aluminum | $25 to $75 | $3,000 to $9,000 | $5,000 to $15,000 | $7,500 to $22,500 |
| Barbed wire | $3 to $6 | $360 to $720 | $600 to $1,200 | $900 to $1,800 |
For fencing cost per meter, multiply the per-foot price by 3.281. Wood privacy at $42.50 per foot works out to about $139 per meter.
Shape changes cost too. The 60 × 40 ft yard uses 4 ft more fence than a 49 × 49 ft square of the same 2,400 sq ft, which is $172 at $42.50 per foot.
How to Measure a Rectangular Fence and Square the Corners
Field measurements, not plan dimensions, belong in the rectangle fence perimeter calculator. Measure each side along the line where the posts will stand, not along a curb or an old fence, and round to the nearest inch. Then check the corners with the diagonal before you dig.
d is the corner-to-corner diagonal. For the 60 × 40 ft yard, d = √(60² + 40²) = 72.11 ft, which reads 72 ft 1-5/16 in on a tape. When both diagonals match that reading, all four corners are square.
The check works the same way as the 3-4-5 rule, scaled up to the whole yard. If one diagonal runs long, shift the far corner stakes along their sides until the two diagonals agree.
Fence Material Size and Concrete
Materials follow the net run and the post layout in the rectangle fence perimeter calculator. Wood pickets are counted per section from picket width plus gap, rails are one set per bay, chain link fabric comes in 50 ft rolls with 21 ft top rail, and barbed wire comes on 1,320 ft spools.
On the 60 × 40 ft privacy fence, 5.5 in pickets set tight need 431 pickets, or 475 with 10% waste. Three 2×4 rails per bay across 26 bays make 78 rails.
Concrete fills the hole around the post. Quikrete's Concrete Mix data sheet lists about 0.60 cu ft per 80 lb bag, so a 10 in hole 30 in deep around a 4×4 post takes 1.15 cu ft, or 2 bags per post.
How to calculate fence height and post length
Quikrete also advises a hole about 3 times the post width and a depth of one third of the post's overall length. That puts two thirds of the post above ground, so the post length is about 1.5 times the fence height.
A 6 ft privacy fence then needs 9 ft posts set 3 ft deep, and a 4 ft picket fence needs 6 ft posts set 2 ft deep. The Fence Post Depth Calculator works that out for other heights and frost depths.
Garden Area vs Perimeter
Area is the ground inside the fence, in square units. Perimeter is the fence around it, in length units. The same fence can enclose very different areas depending on its shape.
Fed 200 ft of fence and a shape ratio, the rectangle fence perimeter calculator works backward to the area. A 50 × 50 ft square encloses 2,500 sq ft, a 2:1 rectangle of 66.67 × 33.33 ft encloses 2,222 sq ft, and a circle would enclose 3,183 sq ft.
Leaving one side open stretches the same fence further. With 200 ft along three sides of a wall, a layout twice as wide as it is deep encloses 5,000 sq ft, double the square.
Fence Perimeter Questions Answered
Unless an answer names another size, the numbers come from the 60 × 40 ft yard with one 4 ft gate, 8 ft post spacing and a wood privacy fence at $42.50 per foot.
What is a rectangular fence perimeter calculator?
A rectangular fence perimeter calculator finds the length of fence around a rectangle from its length and width. A full one also subtracts gates, handles open sides, counts posts side by side, gives the squaring diagonal and prices the run.
This rectangle fence perimeter calculator can also start from an area and one side, an acreage and a shape ratio, or a fence length you already own, and it compares your shape with the most efficient one.
What is a perimeter fence?
A perimeter fence is a fence that runs along the outer boundary of a property or field. The perimeter of a fence is a measurement: the total length around the area it encloses, which is the figure you buy material and labor by.
How do I calculate the linear feet of a fence?
Measure each run in feet and add them, then subtract gate openings, which is the same order the rectangle fence perimeter calculator follows. A linear foot is simply one foot of fence length, so the 60 × 40 ft yard needs 196 linear feet of fence after its 4 ft gate.
Does the calculator account for gates?
Gates are subtracted from the fence run and get two gate posts each, set evenly along the front length. A 4 ft gate cuts 4 ft of fence but adds one more post than plain fence would. Gate leaves and hardware are priced separately.
How do I calculate the length of a ring fence?
A round ring fence is a circle, so its length is π times the diameter. A 60 ft ring needs 188.5 ft of fence. The Round Pen Calculator turns that into panels, gates and cost for horse and livestock pens.
Are circumference and perimeter the same thing?
Circumference is the perimeter of a circle. Both measure the distance around a shape, but circumference is the word used for circles and ellipses, while perimeter covers any shape with straight or curved sides.
How do you find the exact perimeter of an ellipse?
An ellipse has no simple exact formula, so builders use Ramanujan's approximation, which is accurate to well under 0.1% for garden shapes. An oval bed 60 ft long and 40 ft wide (a = 30, b = 20) has a perimeter of about 158.7 ft.
How do I calculate fencing for an irregular shape?
Measure each straight run separately and add them. For an L-shaped or stepped yard, split it into rectangles and count only the outside edges, since shared edges between rectangles get no fence.
The Fence Calculator handles runs of any length, and the Barbed Wire Fence Calculator covers irregular farm fields.
How do I find perimeter in real life?
Walk the line with a long tape or a measuring wheel, recording each side from corner stake to corner stake. On a large field, a property survey or plat gives the boundary lengths, which you can add for the total.
Can contractors use this to quote clients?
Contractors can use the rectangle fence perimeter calculator for the takeoff side of a quote: fence length, posts, bays, pickets, rails and concrete all come straight from the measurements. Enter your own installed price per foot, and add gate leaves, hardware, removal and permits as separate lines.
What does building a fence yourself cost?
Building it yourself removes labor but not materials. The Wood Fence Calculator, Vinyl Fence Cost Calculator and Fence Picket Calculator price the parts for your own build.