Deck Building Codes 101: Ensuring Your Next Project Is Safe and Legal

This is one set of codes you really have to nail down

Outdoor terrace with sofa and chairs
Photo: itchySan / E+ / Getty Images
Outdoor terrace with sofa and chairs
Photo: itchySan / E+ / Getty Images
Barbara Bellesi Zito
Contributing Writer
Updated February 7, 2024

Highlights

  • Local deck building codes are often stricter than those set by the International Residential Code (IRC). 

  • Some examples of deck codes are: Guardrails are required for decks taller than 30 inches; steps must be 36 inches wide or more; wood decks must use lumber sized 5/4 by 4 inches or 5/4 by 6 inches.

  • It pays to have a pro builder do the work to ensure compliance. Otherwise, you can face hefty fines. 

Get quotes from up to 3 pros!
Enter a zip below and get matched to top-rated pros near you.

You can choose the style of wood or composite you want for your new outdoor deck. But local deck building codes guide your deck’s construction. In addition to obtaining the necessary permits, you must follow strict laws to ensure your deck construction is safe and in compliance with local property regulations regarding outdoor living spaces. 

Before you make plans for a backyard gathering in your new outdoor space, here’s what you should know about building codes for residential decks.

Why Are Building Codes So Important?

Building codes ensure that residential and commercial structures are built safely and securely. They are not suggestions. They are rules based on the International Residential Code (IRC), a model that sets the minimum requirements for single-family homes, two-family homes, and townhomes to ensure the safety of their occupants.

In the United States, home builders and contractors must adhere to local building codes, which are based on the IRC but can be even more strict than those rules call for. Outdoor decks are known for having such strict local rules that even advanced DIYers might want to leave this one up to a local deck building company instead.

Angi Tip
Make sure to check local regulations to see if you need a permit to build your deck. Usually, the height, total square footage, and the connection (or lack thereof) to your home will determine whether or not you need to obtain a permit before building.
Kassidy Barber
Content Editor, Angi

Minimum Requirements for Deck Codes

With so many rules governing the safe construction of decks, you’ll likely need a permit to build a deck, especially if you want to attach it to your home. We’ll get into more specific building codes for residential decks soon, but for starters, here are some requirements that are important to know:

Materials

  • Wood decks should use lumber sized 5/4 by 4 inches or 5/4 by 6 inches. The alternative is 2 feet by 4 feet or 2 feet by 6 feet.

  • Composite deck construction must follow all manufacturer guidelines and specifications.

Railings

  • Guardrails/railings are required for decks elevated more than 30 inches from the ground.

  • Stair handrails must be 34 to 38 inches tall measured vertically from the edge of the stair tread, also called the nose.

Stairs

  • Steps must be at least 36 inches wide.

  • Riser heights/tread depths must not vary more than 3/8 of an inch.

Load Strength

  • Minimum of 50 pounds per square foot. 

Footing Posts

  • Follow local building codes for lumber sizes. These typically are 4 feet by 4 feet, 4 feet by 6 feet, 6 feet by 6 feet, or 8 feet by 8 feet. 

Deck Building Code for Attached Decks

Construction of wood deck on patio
Photo: Jennifer J Taylor / iStock / Getty Images Plus / Getty Images

Decks attached to a house require a permit since they’re considered an alteration to the home’s existing structure. While builders should always follow local codes, here are some guidelines:

  • Before attaching the ledger board, you must remove the siding and other exterior finishes.

  • Ledger boards should be 2-inch planks. Though their minimum width depends on the support beams, their depth must be equal to or greater than the joists.

  • Ledger boards and flashing should be installed on the foundation or framing of the house per local building codes.

  • When connecting decks to the foundation and joining floor and deck joists, use tension devices with a load capacity of at least 1,500 pounds.

Deck Building Code for Detached Decks

Detached decks are a different animal because they do not involve the structure or foundation of your home. However, local building codes and permitting policies reign supreme here, especially when it comes to the placement of your deck.

While building codes mainly cover safety and structure, privacy is also at play here in many communities. For example, you probably wouldn’t like it if your neighbor built a detached deck next to your fence so that when they are standing on it, they can see clearly into your backyard. Even if the structure is built soundly, local building codes in your area may dictate things like height, size, and distance from property lines when it comes to building codes for residential decks.

Privacy and common courtesy aside, most of the requirements for attached decking also apply to detached platform decks. However, local considerations that include geography and climate will further impact building guidelines because these will affect the installation and longevity of your deck.

Deck Framing 

The framing of your deck is the overall design and plan for your deck. Far more than just for aesthetics, it outlines how all of the wood or composite components are connected to each other and to your house. It also includes the footing, which is the foundation of your deck. You must present the specs for your deck frame, along with other supporting information, to the local building authorities to secure a permit.

Here are some considerations for deck joists and frames:

  • Joists and beam cantilevers have a maximum length, usually not larger than 1/4 of the joist or beam span length.

  • Joist length is determined by the deck’s size and overall design, though lumber/material guidelines and local codes will make the final call. 

  • Deck joists are spaced at 12 inches, 16 inches, or 24 inches, depending on the type of wood or composite used.

  • Blocking rows must be installed with equal spacing between 4 feet and 6 feet.

  • Rim joist and ledger widths should be equal to or greater than the joist, and they must be securely fastened to the end of each joist.

  • Deck beam bearings are determined by the deck materials. For wood and metal, beam bearings must be at least 1.5 inches. For concrete and masonry, beam bearings must be 3 inches.

  • Deck footings shouldn’t add lateral pressure to the foundation of any adjacent structure, so follow local code guidelines that determine how far the deck must be built from the home.

  • Joist bearings must be secured to beams and joist hangers. 

  • Joint hanger capacities increase with the size of the joist.

Deck Design Components

13 parts of a deck illustrated, including beams, posts, and decking

You should not begin building a deck without a permit or an approved design based on the local building code. Here are some guidelines that will give you an idea of what to consider when assembling the main components of a deck.

Ledger Boards

These are the pieces of lumber or composite that connect the deck to the wall of the house. Most codes require a minimum of 2 inches by 8 inches, but you must also ensure that the anchors and other attachments are compliant.

Footing

This is the foundation of your deck. The footing must be buried at least 1 foot into the ground, but some municipalities require much deeper.

Posts and Beams

These pieces support the joists of the deck. You must ensure that the beams are properly spaced (3/8 of an inch apart) and securely attached.

Joists

These are the boards that attach (via joist hangers) to the ledger, forming the base of your deck. Spacing is also important here, and it depends on the size and material of the joists.

Railings

Just like you need a rail on interior staircases, you need one for your elevated deck. While the railing height is determined by how high the deck is from the ground, expect that you’ll need rails a minimum of 34 inches tall.

Stairs and Stringers

Stairs must be of an adequate height and width to be considered safe to use. The tread width, riser height, and stair edge (nosing) will be determined by local code, as will the load-bearing capacities for stringers, which are the components that support the stairs.

Tips for Building a Deck in Your Backyard

Deck building is a challenge when it comes to building codes. Remember these tips when you’re ready to give your project the green light.

Start With Permits and Local Building Codes

Local building codes, which may reflect or supersede the IRC, serve as your primary guide during the design and construction phases of your deck. Keep in mind that codes are updated every few years. So, if you were delayed in building your deck, you might have to make design adjustments to remain in compliance with any updated deck building codes.

Define Your Deck’s Design

Unlike making last-minute changes with appliances or backsplash tile choices for a kitchen remodel, making changes to the overall design of your deck could easily knock it out of compliance. Before sending your design in for evaluation for permits and code compliance, ensure that all of your desired features are included because it may be very difficult or even impossible to add them on at a later date.

Consider Hiring a Deck Professional

If all this talk of deck building codes is too nerve-wracking, hire a professional deck builder instead. The cost of building a deck is pricey enough without having to redo it because it’s not compliant with local code. Save your burgeoning DIY skills for another project and leave this one to the pros who know how to navigate the complicated process of obtaining permits and complying with complicated codes.

Need professional help with your project?
Get quotes from top-rated pros.
Learn more about our contributor
Barbara Bellesi Zito
Contributing Writer
Barbara Bellesi Zito is a freelance writer from Staten Island, NY, covering real estate investing and home improvement for Millionacres, Apartment Therapy, and others.
Barbara Bellesi Zito is a freelance writer from Staten Island, NY, covering real estate investing and home improvement for Millionacres, Apartment Therapy, and others.
The homeowners guide to Patios
From average costs to expert advice, get all the answers you need to get your job done.