FENCE CALCULATOR

Fence Calculator — Posts, Rails & Material Cost Estimator

Estimate the posts, rails, panels, linear footage and total project cost for your fencing project. Choose from common fence types, enter the total fence length and post spacing to get a complete material and cost estimate.

Fence line

Gates & material

Estimated total cost
—

Enter fence dimensions to see estimate.

How Fence Materials Are Calculated

Posts are spaced at regular intervals along the fence line. The number of posts is:

Posts = (Fence Length ÷ Post Spacing) + 1 + Gate Posts

Rails run horizontally between posts — two rails per span is standard for most styles, three rails for fences over 6 ft. Linear footage equals the total fence length and is used to estimate panel, picket or mesh quantities.

Fence Type Guide

  • Wood privacy (6 ft): Most popular residential fence. Cedar or pressure-treated pine. Needs staining or sealing every 2–3 years. $15–$30/linear ft installed.
  • Vinyl / PVC: No painting or staining, excellent longevity (30+ years), higher upfront cost. $25–$40/linear ft installed.
  • Chain-link: Most economical for large areas. Galvanized or vinyl-coated. $10–$20/linear ft installed.
  • Aluminum: Decorative, rust-free, low maintenance. $25–$35/linear ft installed.
  • Split-rail: Rustic, open design, economical. Good for defining boundaries without enclosing. $10–$20/linear ft installed.

Fence Post Sizing & Depth Guide

Post depth and size depends on fence height and type:

  • 4 ft fence: 4×4 posts, set 2 ft deep (below frost line in cold climates)
  • 6 ft fence: 4×4 or 4×6 posts, set 2.5–3 ft deep
  • 8 ft fence: 4×6 or 6×6 posts, set 3+ ft deep

General rule: set posts 1/3 to 1/2 of total post length in the ground. Use concrete (2–4 bags per post hole) for permanent installations. Gravel-set posts allow drainage but are less stable.

Frequently Asked Questions

How many fence posts do I need for 100 feet of fence?

With 8-foot spacing: (100 ÷ 8) + 1 = 13.5, rounded to 14 posts. Add 2 posts per gate opening. With 6-foot spacing you need 18 posts.

Do I need a permit to build a fence?

Most municipalities require permits for fences over 6 ft, fences in front yards, and fences near property lines. Always check setback requirements with your local planning department before digging posts.

What is the best wood for a fence?

Western red cedar and redwood are naturally rot-resistant and are the premium choices for wood fencing. Pressure-treated pine (ground-contact rated) is less expensive and highly durable. Untreated pine should not be used in ground contact.