For more information please see the Safety Barrier Guidelines for Residential Pools below.
If your fence is not code compliant, instead of replacing it, you can do the below:
Wire Mesh Requirements:
1" x 1" Welded Wire Mesh (Square), 0.8800" x 0.8800" Opening (Square), 0.120" Thick (11 Gauge) Wire Diameter
11 Gauge Steel Twist Wire