Skip to content
← Back to Blog

How Close to the Fence Can You Build? California's Fire Rules

Your neighbor's wall sits right on the property line, but your contractor says yours needs special fire-rated construction? Both can be right. California sets different rules at 2, 3, and 5 feet from the line — here's what changes at each step.

S. N.August 12, 2026
How Close to the Fence Can You Build? California's Fire Rules

You're planning a garage addition, and your contractor says the wall facing the fence has to be built "one-hour fire-rated" — while your neighbor's house sits right on the property line with no special construction at all. Both are following the same rulebook. California regulates walls near a property line for one reason: to keep a fire on one lot from jumping to the next, even if a neighbor builds close on the other side.

The rule lives in the 2025 California Residential Code, § R302.1, and it works by fire separation distance — the code's term for the gap between your wall and the property line. An unrated wall needs 5 feet or more of that gap. A wall closer than 5 feet needs 1-hour fire-resistant construction. Windows and doors are not allowed within 3 feet, and roof eaves may not project within 2 feet. Fully sprinklered homes get a separate, more lenient table.

The distances that matter (Table R302.1(1))

Wall element Condition Minimum fire separation distance
Walls 1-hour rated (tested per ASTM E119, UL 263, or CBC § 703.2.2, exposure from both sides) 0 feet
Walls Not fire-resistance rated ≥ 5 feet
Projections (eaves, overhangs) Not allowed < 2 feet
Projections 1-hour on the underside, heavy timber, or fire-retardant-treated wood ≥ 2 feet to < 5 feet
Projections Not rated ≥ 5 feet
Openings (windows, doors) Not allowed < 3 feet
Openings Up to 25% of the wall area 3 feet
Openings Unlimited 5 feet
Penetrations (vents, pipes) Must comply with § R302.4 < 3 feet
Penetrations No protection required ≥ 3 feet

All rows are from Table R302.1(1) in § R302.1. Two footnotes soften the eave rules: the underside rating of an eave overhang may drop to 0 hours if fireblocking runs from the wall top plate to the roof sheathing, and rake overhangs (the sloped roof edge on a gable end) may drop to 0 hours where the overhang or gable wall has no attic vent openings.

Where the distance is measured from

Fire separation distance is measured from the wall to the lot line — and the code fills in the gaps for buildings that share a lot. Two homes on the same lot are treated as if an imaginary property line ran between them, and a new building must be placed so the existing one still complies. For townhouses, the rule is explicit:

"Where a lot line exists between adjacent townhouse units, fire separation distance of exterior walls shall be measured to the lot line." — § R302.1

Where no lot line exists between townhouse units, an imaginary line is assumed between them. Walls between attached townhouse units follow a different rule (§ R302.2), not fire separation distance.

The five exceptions

§ R302.1 lists five carve-outs:

  1. Perpendicular walls — walls, projections, openings or penetrations that sit perpendicular to the line used to measure fire separation distance.
  2. Same-lot buildings — walls of individual dwelling units and their accessory buildings on the same lot.
  3. Permit-exempt sheds — detached tool sheds, storage sheds, playhouses and similar permit-exempt structures need no wall protection based on location, but their roof edges may not extend over the lot line.
  4. Detached garages near the line — a detached garage within 2 feet of a lot line may have roof eaves projecting up to 4 inches.
  5. Foundation vents installed per the code.

Sprinklered homes get a friendlier table

A home — and its accessory buildings — equipped throughout with an automatic sprinkler system per Section R309 may use Table R302.1(2) instead, which relaxes the requirements at close distances. There is a catch for garages: where a garage wall is designed under Table R302.1(2), Note a, § R317.5 requires the private garage itself to be protected by residential or quick-response sprinklers at a density of 0.05 gpm/ft², connected to the R309 system — and garage doors are not considered obstructions to sprinkler spray.

Bigger buildings play by different rules

R302.1 covers one- and two-family homes and townhouses. Larger buildings fall under the California Building Code instead: § 705.6 requires an exterior wall's fire rating to run from the top of the foundation up to the roof or a rated assembly above, and a wall sitting on the lot line between adjacent buildings is a party wall under § 706.1.1, built as a fire wall with no openings at all.

The building code is the floor — zoning usually controls

These rules are a statewide construction standard: they tell you how a wall near the line must be built, not whether your city lets you build there at all. Local zoning setbacks (commonly larger than 5 feet for side and rear yards) apply first, and cities can also amend the building code locally. Check your city's zoning code and any local amendments before designing to these minimums.

Sources