What the animation shows
The animation and the step-by-step video above use your numbers. Here is the same walkthrough written out for the default example.

What you enter
- Total fence length: 100 ft.
- Number of gates: 1.
- Gate width (each): 4 ft.
- Panel width: 8 ft.
- Post width: 3.5 in.
What happens, step by step
- Posts first: one per panel plus one, and one more per gate.
- Each 8 ft panel drops in between two posts.
- Posts take up width too, so each bay is a panel plus a post.
- The leftover is short, so the last panel is cut to 4.2 ft.
The answer: panels is 12.
How it’s calculated
- Panels = (fenced length − post width) ÷ (panel width + post width), rounded up
- Posts = panels + 1 + gates
Worked example
100 ft with one 4 ft gate, 8 ft panels, 3.5 in posts.
Inputs
- Total fence length
- 100 ft
- Number of gates
- 1
- Gate width (each)
- 4 ft
- Panel width
- 8 ft
- Post width
- 3.5 in
- Price per panel
- 0 $
- Price per post
- 0 $
Results
- Panels
- 12
- Posts
- 14
Assumptions and limits
- One straight run; each corner adds a post.
- The last panel may need to be cut to length.
Verify the result against the applicable local code, adopted code edition, manufacturer instructions and project requirements. See our methodology.
Questions
Do panel widths include the post?
Usually not. An 8 ft panel spans 8 ft between posts, so each bay uses 8 ft plus one post width.
How do I handle a short last section?
Most wood and vinyl panels can be cut down. Check the manufacturer for vinyl rail cutting instructions.