Skip to content
SetbackIQ

Height limits in San Francisco, CA

Building codes decide when you need a permit; zoning decides how tall you can go. Both are below, measured the way San Francisco measures them.

A person last checked these rules on October 22, 2026. This is guidance only, so confirm with San Francisco before you build.

Citywide

ADU: Detached ADU height18 ft under the State program on any lot with a home, plus 2 ft for a roof pitch matching the house
ADU: Attached ADU height (minimum a city must allow)25 ft or the house's height limit, whichever is lower

Check your lot

What are you building?
Aerial close-up of one Bethesda lot with its setback zones shaded and about 1,760 square feet of buildable area for a shed highlighted60 ft from front lineSide and rear 5 ftBuildable area~1,760 sq ft
Example: where a shed can go on a real R-60 lot in Bethesda, Maryland. Your lot gets its own rules.

Sources

  1. San Francisco Ordinance No. 146-25 (File No. 250284), Planning and Building Codes - Noncomplying, Unpermitted, and Accessory Structures. Checked 2026-10-23
    One-story detached accessory buildings or structures used as tool and storage sheds, playhouses, [and similar uses, provided the floor area does not exceed 120 square feet; finally passed July 29, 2025, effective September 5, 2025 per the Planning Code hist…
  2. SF DBI Technical Services, Frequently Asked Questions, Storage Sheds Exempt from a Building Permit. Checked 2026-11-02
    provided the floor area does not exceed 120 square feet... not more than 10 feet high per San Francisco Planning Code Section 136(c)23... [A shed over 120 sq ft or 10 ft] requires a building permit with plans and the approval of the San Francisco Planning D…
  3. sf.gov, Check if your construction project needs a permit. Checked 2026-10-23
    One-story detached accessory buildings or structures used as tool and storage sheds, playhouses and similar uses, if the projected roof area is less than 100 square feet (9.29 m2) and no taller than 8 feet... Fences less than 6 feet (1829 mm) high located a…
  4. sf.gov, Apply for an electrical permit. Checked 2026-10-22
    You need an electrical permit before installing new wiring or alterations, extensions, or additions [to existing electrical installations]... Only owner-installers of stand-alone single family dwellings may apply for an electrical permit to do the work them…
  5. sf.gov, Apply for a plumbing and mechanical permit. Checked 2026-10-22
    [You need a permit before] cutting into or replacing pipes that transport water, gas, hot air, or cool air... Contractors must hold a C4, C16, C20, C36, C54, B, or A license to apply for a plumbing or mechanical permit in general.
  6. 44 CFR 59.1, definition of development (NFIP). Checked 2026-10-19
    Development means any man-made change to improved or unimproved real estate, including but not limited to buildings or other structures...
  7. 44 CFR 60.3, floodplain management criteria. Checked 2026-10-19
    Require permits for all proposed construction or other development in the community...
  8. San Francisco Planning Code § 136(c)(22)-(23), permitted obstructions in required yards (American Legal, current through Ord. 10-26, eff. 3/16/2026). Checked 2026-10-23
    [Permitted in required Yards] (22) Garden structures enclosed by walls on no more than 50 percent of their perimeter, such as gazebos and sunshades, if no more than eight feet in height above grade and covering no more than 60 square feet of land; (23) One …
  9. San Francisco Planning Code § 134(c)(1), rear yards (American Legal, as amended by Ord. 245-25, eff. 1/12/2026). Checked 2026-10-23
    (1) In RH, RM-1, RM-2, RTO-1, and RTO-M Zoning Districts, the basic rear yard shall be equal to 30% of the total depth of the lot on which the building is situated, but in no case less than 15 feet.
  10. 2024 IRC R105.2, Work exempt from permit (text published by the City of Benson, AZ). Checked 2026-10-19
    One-story detached accessory structures, provided that the floor area does not exceed 200 square feet. Fences not over 7 feet high. Decks not exceeding 200 square feet in area, that are not more than 30 inches above grade at any point, are not attached to a…
  11. San Francisco Planning Code § 136(c) (GoCodebook copy, current through Ord. 10-26, effective 3/16/2026). Checked 2026-10-22
    (16) Decorative railings and decorative grille work, other than wire mesh, at least 75 percent open to perpendicular view [and] no more than six feet in height above grade... (13) Retaining walls that are necessary to maintain approximately the grade existi…
  12. San Francisco Planning Code § 132, front setback areas (GoCodebook copy, current through Ord. 10-26). Checked 2026-10-22
    No motor vehicle, trailer, boat or other vehicle shall be parked or stored within any such area... in every case not less than 20% of the required setback area shall be and remain unpaved and devoted to plant material... The front setback area shall be at l…
  13. sf.gov, Get a building permit for an accessory dwelling unit (ADU). Checked 2026-10-22
    Next you will need to decide whether to apply using the State or Local ADU program... ADUs using the Local program require in-house review by the Planning Department... A building permit is required to do construction in San Francisco... A separate mechanic…
  14. SF Planning, Accessory Dwelling Units. Checked 2026-10-22
    Two ADU Programs are available for single-family buildings: Local and State... No, State and Local ADU programs cannot be combined... 4 or less legal dwelling units on the lot: 1 ADU + 1 Detached ADU allowed... ADUs in the Local Program will be subject to t…
  15. SF Planning Director Bulletin No. 3, State Accessory Dwelling Unit Program (updated June 2026). Checked 2026-11-02
    1 Detached ADU is allowed on a lot with an existing or proposed single-family building... Studio and 1-bedroom ADUs are allowed up to 850 square feet. 2+ bedroom ADUs are allowed up to 1,000 square feet. Maximum height. Up to 18 feet. An additional 2 feet i…
  16. San Francisco Planning Code §§ 207.1 (Local ADU Program, through Ord. 170-25) and 207.2 (State-Mandated ADU Program, through Ord. 222-25, effective 12/22/2025) (GoCodebook copy). Checked 2026-10-22
    [207.1(c)(15): one detached ADU may be placed in the required rear yard, at least four feet from the side and rear lot lines, no taller than 16 feet, 850 sq ft (one bedroom or less) or 1,000 sq ft] ... [207.2(d)(9)(A)] A height of 18 feet for a detached ADU…
  17. HCD Accessory Dwelling Unit Handbook (March 2026). Checked 2026-10-19
    A setback of no more than four feet from the side and rear lot lines shall be required for an attached or detached ADU (Gov. Code, 66314(d)(7)).
  18. San Francisco Building Code (2019 edition, archived on American Legal), Section 106A.2 Work exempt from permit. Checked 2026-10-22
    Fences not over 6 feet (1829 mm) high located at the rear and side lot lines at the rear of the property, and all fences not over 3 feet... One-story detached accessory buildings or structures used as tool and storage sheds, playhouses and similar uses, pro…
  19. SF Planning, General Information - Fences (January 2019). Checked 2026-10-22
    A building permit is not required for a fence that is three feet or less in height at the front [and] six feet or less in height at the side or rear property lines... If you propose a fence within the required front setback area, it is limited to a height o…