Skip to content
IRC Section R507

Deck Building Code Requirements

Every structural requirement your deck must meet under the International Residential Code. Railing height, footing depth, joist spans, stairs, and more.

Local codes may be stricter

The IRC provides the baseline. Many cities and states adopt amended versions with stricter requirements (e.g., 42-inch railings instead of 36-inch, deeper frost line footings). Always check with your local building department for adopted code amendments.

Railing & Guard Requirements

IRC R507.8
Guard requiredAny deck surface 30+ inches above grade
Minimum guard height36 inches for residential (42 inches in some jurisdictions)
Baluster spacingMaximum 4 inches between balusters (a 4-inch sphere cannot pass through)
Top rail gripMust be graspable — 1.25" to 2" diameter for handrails on stairs
Infill panelsGlass, cable, or mesh infill must meet same 4-inch opening rule

Footing & Foundation Requirements

IRC R507.3
Frost line depthFootings must extend below the local frost line (12-60 inches by region)
Minimum footing sizeTypically 16-24 inches diameter for residential post footings
Bearing capacitySoil must support the load — 1,500 PSF assumed for most soils
Concrete strengthMinimum 2,500 PSI concrete for footings
Post-to-footing connectionApproved post base connectors required (no direct soil contact for wood)

Joist Span Tables

IRC R507.5
2x6 at 16" OCUp to 7' 11" (Southern Pine) / 6' 10" (SPF)
2x8 at 16" OCUp to 10' 6" (Southern Pine) / 9' 1" (SPF)
2x10 at 16" OCUp to 13' 5" (Southern Pine) / 11' 7" (SPF)
2x12 at 16" OCUp to 16' 5" (Southern Pine) / 14' 2" (SPF)
Cantilever limitMaximum 1/4 of the allowable joist span

Ledger Board Attachment

IRC R507.6
Fastener type1/2" lag screws or through-bolts into the band joist (not just siding)
SpacingPer IRC Table R507.6 — based on joist span and tributary width
Flashing requiredSelf-adhering membrane or metal Z-flashing behind and over the ledger
Prohibited attachmentsCannot attach to cantilevered floors, brick veneer, or SIP walls without engineering
Gap1/2" minimum gap between ledger and siding for drainage

Stair Requirements

IRC R507.8
Maximum riser height7 3/4 inches
Minimum tread depth10 inches
Riser uniformityMaximum 3/8" variation between any two risers
Stair widthMinimum 36 inches
HandrailRequired on stairs with 4 or more risers, 34-38 inches above stair nosing
LandingMinimum 36" x 36" landing at top and bottom

Structural Load Requirements

IRC R507.1
Live load40 PSF (people, furniture, snow)
Dead load10 PSF (the deck structure itself)
Total design load50 PSF minimum
Hot tub loads100+ PSF — requires engineered support (not covered by prescriptive code)
Lateral loadsDeck must resist lateral forces — bracing or moment connections required

Beam Span Tables

IRC R507.5
2-ply 2x8Up to 6' 8" span with posts at 8' joist span (Southern Pine)
2-ply 2x10Up to 8' 6" span with posts at 8' joist span (Southern Pine)
2-ply 2x12Up to 10' 3" span with posts at 8' joist span (Southern Pine)
3-ply requiredWhen spans exceed 2-ply capacity
Post sizeMinimum 6x6 for posts over 8' tall; 4x4 allowed for shorter posts

Decking Material Requirements

IRC R507.4
Wood speciesMust be naturally durable (cedar, redwood) or pressure-treated to 0.40 retention
Board spacing1/8" minimum gap between deck boards for drainage
FastenersHot-dipped galvanized, stainless steel, or approved composite fasteners
Ground clearanceMinimum 6 inches between bottom of joists and grade for ventilation
Composite deckingMust meet ASTM D7032 for structural performance and fire rating

Most Common Code Violations

These are the issues inspectors catch most often. Avoiding these will save you time and money on re-inspections.

Improper ledger board attachment

Using nails instead of lag screws/through-bolts, or attaching to siding instead of the band joist. This is the #1 cause of deck collapse.

Missing or inadequate flashing

No flashing behind the ledger board leads to water intrusion, rot, and structural failure over time.

Footings above frost line

Footings that don't extend below the frost line will heave and shift during freeze-thaw cycles.

Incorrect railing height or baluster spacing

Railings below 36 inches or balusters spaced more than 4 inches apart fail every time.

Stair riser/tread inconsistency

More than 3/8-inch variation between risers creates a trip hazard and is a code violation.

Inadequate post-to-beam connections

Posts simply placed on top of beams without approved hardware can shift under lateral loads.

Deep Dives by Code Topic

The detailed guide for each code section, with state variations, common failures, and the measurements inspectors actually check.

Code requirements are based on the 2021 International Residential Code (IRC) Section R507. Your local jurisdiction may have adopted amendments or different code editions. Always verify requirements with your local building department before construction. This is not engineering advice.