California Pool Gate and Fence Code, Explained for Homeowners
When the California pool barrier rules apply
California pool gate and fence code comes mainly from the Swimming Pool Safety Act, Health and Safety Code section 115920 and the sections that follow it. Since January 1, 2018, when a building permit is issued to build a new pool or spa, or to remodel an existing one, at a private single-family home, the pool must have at least two of seven drowning prevention safety features.
That means a pool remodel in a Pleasanton or Danville backyard, not just a brand-new pool, can bring the barrier question to the table. Local building codes add their own detail, and cities can amend them, so treat this guide as an orientation, not a substitute for your building department's handout. Planning a pool gate? Call (925) 438-6219.

The seven drowning prevention features
The statute lets you choose any two of these:
- An enclosure that isolates the pool or spa from the house (the fence and gate option this guide focuses on)
- Removable mesh pool fencing meeting ASTM F2286, with a self-closing, self-latching gate that can take a key lock
- A safety pool cover meeting the ASTM F1346 standard
- Exit alarms on the doors that open directly to the pool area
- Self-closing, self-latching devices on house doors that open directly to the pool, with the release no lower than 54 inches above the floor
- A pool alarm certified to ASTM F2208 that sounds when someone enters the water
- Another means of protection approved by the building official as equal to or better than options 1 through 4
Many families pair a permanent enclosure with door alarms or self-closing door hardware, because a fence works without anyone remembering to set it. A cover or alarm can be a good second layer, but each depends on someone closing, arming or maintaining it every time.
Planning a railing project in San Ramon or the Tri-Valley? We measure on site for free and give you a written range before anything is fabricated.
Enclosure and gate requirements
Section 115923 sets the core numbers for an enclosure. Pleasanton's pool handout (revised January 2020) restates them for local permits:
| Requirement | What the rule says |
|---|---|
| Enclosure height | At least 60 inches, measured on the side away from the pool |
| Gap at the bottom | No more than about 2 inches between grade and the bottom of the barrier |
| Openings | Must not pass a 4-inch sphere |
| Climbability | Outside face free of handholds and footholds a child under five could use to climb over |
| Gate swing | Opens outward, away from the pool |
| Gate closing | Self-closing, with a self-latching device |
| Latch height | Release placed no lower than 60 inches above the ground |
The California Residential Code's pool barrier provisions add more detail, including when a gate release can sit lower if it is placed on the pool side of the gate with small openings around it. Those specifics, and any local amendments, are worth confirming with your building department before fabrication.
Designing a pool gate that passes and lasts
- Picket spacing. We space pickets so no opening passes a 4-inch sphere, including under the bottom rail and at the hinge side.
- Horizontal rails. Rails on the outside face can work like ladder rungs. We keep structural rails on the pool side or lay them out so they do not form steps; ask your department for its spacing rule.
- Closers and hinges. Spring hinges or a hydraulic closer sized to the gate's weight, adjusted so the gate closes and latches from any open position.
- Latch hardware. A pool-rated latch with the release at the required height, plus provision for a lock.
- Finish. Galvanized or zinc-primed steel under powder coat, because splash and chlorine are hard on bare steel.
Tri-Valley backyards: inspections and practical notes
Backyard pools are common in the Tri-Valley's single-family neighborhoods, and inspectors want to see the barrier before the pool is filled. Pleasanton's handout, for example, says the enclosure must be installed and working before water is introduced, typically at the pre-plaster inspection, and that the two drowning prevention features must be in place at final inspection.
Hillside lots in Danville, Alamo and San Ramon raise their own issues: a gate on a slope needs a closer strong enough to swing it uphill, and the bottom gap has to be checked along the whole run, not just at the hinge. If your yard is also behind HOA walls, plan on architectural review for the gate design.
Remodels catch people by surprise. Replastering, new decking or a spa addition that needs a permit can bring the two-of-seven requirement with it, so it pays to plan the gate and fence work alongside the pool contractor's schedule instead of after it.
Common pool gate mistakes
Most barrier problems we are asked to fix fall into a short list:
- A gate that swings toward the pool. Often the result of reusing an old side-yard gate. Re-hanging it to swing out, away from the water, may mean new posts.
- Closers that quit. Spring hinges lose tension over a few hot summers. If the gate stops short of latching from a half-open position, it is no longer self-closing in practice.
- Latches mounted for adult convenience. A latch at hand height is easy to use and easy for a child to reach. Keep the release where the rules put it.
- Gaps that grew. Settled pavers, eroded soil under the fence or a gate that sags on its hinges can open the bottom gap past the limit.
- Climbing aids. Pool equipment, planters, benches or a wall placed against the outside of the fence can defeat a barrier that met code on inspection day.
Test your gate from several open positions every season. It should swing shut and latch every time without a push.
How we build pool gates
We fabricate steel and aluminum pool gates and matching fence sections in our shop, sized to your opening and checked against the enclosure rules on the drawing before anything is cut. We can match an existing iron fence so the pool enclosure looks like part of the yard rather than an add-on, and we hang and adjust the closer and latch on site so the gate shuts reliably from any position.
Browse custom gates and wrought iron railings for styles, see our Pleasanton and Danville pages for local permit details, then call (925) 438-6219 or request a free on-site estimate.
FAQ
Questions, Answered
Straight answers on cost, code, permits and materials. Still unsure? Call and ask.
How high does a pool gate latch have to be in California?
Under Health and Safety Code section 115923, the self-latching device on an enclosure gate is placed no lower than 60 inches above the ground. The residential code has a separate path that can allow a lower release on the pool side of the gate with small openings around it. Confirm which approach your building department accepts before you buy hardware.
Which way should a pool gate swing?
Outward, away from the pool. A child pushing on the gate from outside the enclosure should be pushing it closed, not open. The gate must also be self-closing and self-latching, so it shuts and latches on its own from any open position. If an existing gate swings the wrong way, it can often be re-hung, sometimes with new posts.
Do I have to upgrade my pool fence if I am not remodeling?
The state's two-of-seven rule is triggered when a building permit is issued for a new pool or spa or a pool remodel at a single-family home. Some cities also have their own ongoing barrier requirements, and Pleasanton's handout calls for an enclosure maintained at all times. Check your city's rules, and consider upgrading anyway if young children live in or visit the home.
Can a wrought iron fence work as a pool barrier?
Yes, if it is designed for it: at least 60 inches tall, openings that will not pass a 4-inch sphere, no climbable horizontal rails on the outside face, a small gap at the bottom, and a self-closing, self-latching gate that swings away from the pool. Many decorative fences need tighter picket spacing to qualify.
Need Help in San Ramon?
San Ramon Custom Railing builds custom iron, cable, glass and aluminum railings across San Ramon, CA and the Tri-Valley. If this guide answered your question, the next step is a free on-site measure and a written range. See everything we do on our homepage, or reach out now.


