×
Back Button

How to Build a Gate for a Deck

Chris Deziel

Build a simple deck gate that's attractive and up to code using new lumber or recycled railing material.

Making a gate for your deck is a straightforward project, but you must follow certain code requirements designed for the safety of people using the deck -- especially children. A code-compliant design that works for most decks incorporates vertical balusters attached to a top and bottom rail. This is an easy design to execute with either new lumber or material left over from construction of the deck platform.

Safety Requirements

Both the International Residential Code and International Building Code specify a minimum height for deck handrails; the IBC requirement is more stringent and -- for safety's sake -- it's the one to which you should conform.

  • It specifies a minimum height of 42 inches above the deck surface, and that is the height you should make your gate.
  • The balusters must be spaced closely enough to prevent a 4-inch sphere from passing between them, and the distance between the bottom of the gate and the decking should be no more than 4 inches when the gate is closed. 
  • The gate should open onto the deck -- not onto the stairs or the ground -- and be hung with strap hinges that can support its weight. 

Attach the hinges to the gate's top and bottom rail. The top rail and each square foot of baluster area must be strong enough to support a force of 125 pounds.

Procedure for Building a Simple Gate

If you have material left over from building the deck rails, you can use it to build the gate. Otherwise, you'll need two-by-four lumber for the rails and one-by-two lumber for the balusters.

  1. Measure the distance between the gate posts, using a tape measure. Subtract 1/2 inch from this measurement and cut two lengths of two-by-four lumber to this length, using a circular saw. These are the gate rails.

  2. Cut enough 42-inch lengths of one-by-two lumber to arrange on on the rails so that none are separated by more than 4 inches. You can make the spacing less if you want.

  3. Lay the rails on a flat surface and arrange them so they are parallel and their outside edges are separated by 36 inches. Screw a baluster to one end of the rails so it overhangs each rail by 3 inches. Screw another baluster to the other end of the railing in the same way. Use 2-inch exterior wood screws.

  4. Measure the spacing between the balusters and divide that number by the number of balusters you have left to determine the spacing between each pair. Screw the balusters to the rails.

  5. Attach strap hinges to each of the rails with the screws that come with the hinges. Support the gate in place between the posts, making sure the distance between the bottom of the gate and the deck is less than 4 inches. Push the gate tight against the hinge post and screw the hinges to the post. Open and close the gate to make sure it swings freely.

  6. Attach a barrel latch to the top rail on the other side of the gate and screw the latch holder to the post.

A More Complex Design

In one design variation, construct a 42-inch high frame, using two-by-fours, and attach the balusters flush with the edges of the top and bottom rail. This design usually requires a diagonal brace -- you can screw another two-by-four inside the frame or attach tension wire. The lower part of the brace should be on the hinge side for maximum stability.

The Drip Cap

  • Making a gate for your deck is a straightforward project, but you must follow certain code requirements designed for the safety of people using the deck -- especially children.
  • The top rail and each square foot of baluster area must be strong enough to support a force of 125 pounds.
  • If you have material left over from building the deck rails, you can use it to build the gate.
  • Cut enough 42-inch lengths of one-by-two lumber to arrange on on the rails so that none are separated by more than 4 inches.
  • You can make the spacing less if you want.
  • Push the gate tight against the hinge post and screw the hinges to the post.