Sag-proof math

Fence Gate Builder

A gate that stays square for years: exact cuts, the diagonal brace angle that actually prevents sag, and every piece of hardware.

45.0°brace angle

Diagonal brace: 58.0 in. at 45.0° — bottom hinge side to top latch side.

Cut list

    Hardware

      Posts: 2× 4×4 (6×6 for gates over 5 ft wide), set 30 in. deep in concrete. Leave 1/2– in. clearance each side of the gate.

      Why Gates Sag (and the One Brace That Stops It)

      Every wooden gate wants to become a parallelogram. Gravity pulls the free (latch) side down, the frame racks, and within a season the latch no longer meets the strike. The fix is not heavier wood or more screws — it is a diagonal brace in compression, running from the bottom of the hinge side to the top of the latch side.

      Direction matters absolutely. The brace must push up against the sagging corner, which means low on the hinge post, high on the latch side. Flip it — high hinge to low latch — and the brace hangs in tension, doing nothing while the gate sags exactly as before. Walk any neighborhood and you can spot the flipped braces by the gates dragging on the ground beneath them.

      The calculator gives you the brace's exact length (the hypotenuse of the inside frame) and its angle, so you can set the miter saw once and cut it right. Cut the brace slightly long and tap it into place — a compression fit that you have to persuade is a brace that stays put.

      Sizing the Opening

      Measure the opening between the posts, not the old gate. Build the gate frame 1 to 1.5 inches narrower than the opening: about 1/2 to 3/4 inch of clearance per side for the hinges and seasonal swelling. A gate built tight in July will not close in January.

      Standard walk gates run 36 to 48 inches wide; 42 inches is the sweet spot that admits a wheelbarrow without admitting regret. Double gates for driveways split the opening — each leaf follows the same math, and each leaf wants its own diagonal brace. Keep single leaves under about 6 feet wide; beyond that, the leverage defeats wood joinery and you are in steel-frame territory.

      Height should match the fence — typically 48 to 72 inches. Taller gates catch more wind, which is a real load: a 6-foot solid gate in a gust sees serious force at the hinges. If your site is windy, consider spaced pickets instead of solid boards to let air through.

      The Frame: Stiles, Rails, and Real Dimensions

      The frame is four pieces of 2x4: two full-height stiles and two rails that fit between them. With 3.5-inch-wide 2x4s, each rail is the gate width minus 7 inches — the calculator does this subtraction for you. Use pressure-treated lumber or cedar; untreated pine becomes compost.

      Joinery: exterior screws (2.5-inch) driven through the stiles into the rail ends, two per joint, pre-drilled. Fancy mortise-and-tenon joints are lovely and unnecessary — the diagonal brace carries the structural load; the corner joints just hold the rectangle together while you fit it. A bead of exterior wood glue at each joint is cheap insurance.

      Add a mid rail if you are nailing pickets to the frame — it gives the picket middles something to bite. For open-frame gates (no pickets), the mid rail is optional but adds welcome stiffness on wide gates.

      Cutting the Diagonal

      The brace spans the inside of the frame corner to corner: run equals gate width minus 7 inches, rise equals gate height minus 7 inches. Length is the hypotenuse; angle is the arctangent of rise over run. For a square 48-by-48 gate that is 58 inches at exactly 45 degrees — the prettiest number in gate building.

      Set the miter saw to the brace angle (not its complement — dry-fit first, trust the calculator second, your eyes last). Cut one end, hold it in the frame, mark the other end in place, then cut. In-place marking forgives every measuring sin, including the frame not being perfectly square.

      Fit the brace inside the frame, flush or slightly recessed, screwed through the rails and stiles into its ends. Some builders add a second diagonal forming a Z — unnecessary if the first is correct, but harmless. What actually helps on wide gates is a tension cable with turnbuckle as a complement: the wood brace pushes, the cable pulls, and the gate stays square for a decade.

      Hinges: Where Cheap Gets Expensive

      Buy the longest strap or T-hinges that look right — 8 to 10 inches for a walk gate. Long hinges spread the load across more of the stile instead of concentrating it at two screws that will wallow out. Two hinges suffice up to about 4 feet wide; use three beyond that, with the middle hinge slightly closer to the top.

      Screw hinges into the stile, never just into pickets, with 2.5-inch exterior screws that bite deep. The post-side hinge screws should be longer still — 3-inch — because the post carries the whole gate's weight times leverage. Pre-drill everything; splitting a stile at the hinge is a special kind of heartbreak.

      Adjustable hinges exist and are worth the premium on heavy gates: a turn of a wrench re-levels a gate that has settled, instead of a Saturday with shims. Self-closing hinges are required by code around pools in most jurisdictions — check before you build.

      Latches and the Strike Side

      A gravity latch is simple and reliable: the arm drops into the catch when the gate swings shut. Mount it at a comfortable 48 inches high, out of small children's reach if that matters. Lever latches operable from both sides cost more and are worth it on gates you use daily.

      The strike side needs a solid target — a dedicated strike post or a reinforced section of fence. The classic failure is latching to a wobbly fence rail that flexes; the gate then rattles in wind and the latch wears. If the fence run is light, sink a proper 4x4 just for the strike.

      Add a gate stop — a small block the gate closes against. It takes the slam load instead of the latch, which doubles latch life and stops the gate from swinging through in wind.

      Posts: The Foundation Nobody Sees

      Gate posts work harder than any other post in the fence: they carry the gate's weight on a lever arm, resist wind, and take slam loads. Use 4x4 minimum, 6x6 for gates over 5 feet wide or heavy solid designs. Set them 30 inches deep (below frost line where applicable) in concrete, bell the hole bottom slightly, and crown the concrete to shed water.

      Let concrete cure 48 hours before hanging the gate — green concrete creeps under load and the post leans by degrees that matter at the latch. Brace the posts plumb while curing; a post that cures out of plumb is a gate that never latches right.

      The hinge post deserves extra: a deeper hole, more concrete, and ideally a diagonal kick brace to the next fence post for wide gates. Every degree the hinge post leans multiplies at the latch side — a 1-degree lean on a 4-foot gate drops the latch corner nearly an inch.

      Pickets, Gaps, and Finishing

      If the gate carries pickets to match the fence, cut them all to the same length with a stop block and keep a consistent gap — 1/4 to 1/2 inch for airflow, tight for privacy. Start from the center and work outward so any odd spacing lands symmetrically at the edges, or start at the hinge side so the latch side looks clean.

      Screw pickets (do not nail) with two exterior screws per rail — screws hold against warping where nails surrender. Pre-stain or pre-paint pickets before hanging, especially the edges; touch up after. Bare wood edges behind pickets are where rot starts.

      Finish the whole gate — all six sides of every board, including ends and the bottom — with exterior stain or paint. End grain drinks water; sealed end grain does not. Re-coat every two to three years and the gate outlasts the fence around it.

      The Annual Five-Minute Tune-Up

      Once a year, walk the gate with a screwdriver: tighten hinge screws (they loosen as wood cycles), check the latch alignment, and look at the brace — it should still be tight in its seat. A brace that has worked loose can be re-wedged or shimmed in minutes; ignored, it lets the sag begin.

      Spray hinges and latch with a dry lubricant, not oil that attracts grit. Check the bottom clearance: if the gate has started kissing the ground, a turnbuckle cable or an adjustable hinge buys years before any rebuild conversation.

      And keep vegetation off it. Vines look romantic and hold moisture against wood, which is rot's favorite invitation. Five minutes with pruners each spring is the cheapest gate maintenance ever invented.

      Frequently asked questions

      Which way should the diagonal brace go on a fence gate?

      From the bottom of the hinge side to the top of the latch side. In this orientation the brace works in compression, pushing up against sag. Reversed (high hinge to low latch), it hangs in tension and does nothing — the gate will sag.

      How do you calculate the diagonal brace length for a gate?

      It's the hypotenuse of the inside frame: brace = √((width−7)² + (height−7)²) for 2×4 framing, and the angle is arctan(rise/run). A 48×48-in. gate gives a 58-in. brace at 45°. The calculator figures it for any size.

      How many hinges does a fence gate need?

      Two hinges for gates up to 4 ft wide; three for wider or heavy gates, with the middle hinge biased toward the top. Use 8–10 in. strap or T-hinges, screwed into the stile (not just pickets) with long exterior screws.

      How much smaller than the opening should a gate be?

      Build the frame 1 to 1.5 inches narrower than the post-to-post opening — about 1/2 to 3/4 in. clearance per side for hinges and seasonal swelling. A gate built tight in summer won't close in winter.

      How deep should gate posts be set?

      At least 30 inches deep in concrete (below the frost line in cold climates), with the hole bottom slightly belled and the concrete crowned to shed water. Use 6×6 posts for gates over 5 ft wide. Let concrete cure 48 hours before hanging.

      Why does my gate drag on the ground?

      Sag: the latch side has dropped because the diagonal brace is missing, reversed, or loose — or the hinge post has leaned. Check the brace first (it should run low-hinge to high-latch and be tight), then the post plumb. A turnbuckle cable or adjustable hinge can re-level it without rebuilding.