STATEWIDE FENCE LAWS IN PENNSYLVANIA

OVERVIEW

Pennsylvania fence projects can involve local zoning, the statewide Uniform Construction Code, utility protection, farm boundary-fence law and private property rights. The applicable rules depend on the municipality, the property’s use and the work. A pool enclosure, livestock fence and ordinary privacy fence are different legal subjects. Updated November 2026.

The residential building-permit exemption for fences no more than six feet high is not a statewide permitted fence height, setback or material list. Separate zoning, pool, road, floodplain and private restrictions can still apply. Government approval does not determine a disputed boundary or a neighbor’s contribution obligation.

Companion guide: Fence Rules in Pennsylvania.

LOCAL AUTHORITY AND THE UNIFORM CONSTRUCTION CODE

Start with the actual city, borough, incorporated town or township, not just the postal address. Pennsylvania townships are municipal governments, not merely fence-viewer districts. Zoning administration, building-code enforcement, roads and environmental approvals can involve different offices. A county planning department’s existence does not establish county zoning on every parcel.

Under Municipalities Planning Code Sections 601–603, covered municipalities may adopt zoning ordinances governing structures, yards and land use. County zoning under Section 602 reaches municipalities without their own zoning ordinance under its stated conditions; a municipality’s later ordinance displaces county zoning within that municipality. Philadelphia and Pittsburgh require their own applicable enabling and local systems rather than automatic application of every MPC provision.

The UCC is a statewide construction framework with Pennsylvania amendments, not an unchanged model code. Its 2021-code update took effect January 1, 2026. Applicable contract-transition provisions and legally retained or approved local requirements need separate attention. An old handout quoting a previous edition does not decide a new project’s code.

For covered residential work, 34 Pa. Code Section 403.62(c)(1) exempts fences NO MORE THAN SIX FEET high from the building permit, provided the work does not violate a law or ordinance. Exactly six feet is included. It does not waive a separate local fence or zoning approval, or permit an otherwise prohibited fence. Ordinary repair has its own exclusions, including structural, egress and specified system work.

Municipal opt-out does not mean the UCC disappears. In an opt-out municipality, residential applicants obtain certified third-party plan-review and inspection services. Opt-in municipalities administer the program themselves or through their authorized arrangements. Confirm who handles each approval for the actual property.

FENCE-POST EXCAVATION AND PENNSYLVANIA ONE CALL

Pennsylvania’s Underground Utility Line Protection Law defines covered excavation around POWERED EQUIPMENT or EXPLOSIVES moving earth or other material, including augering, digging and driving-in. A powered post-hole auger can trigger it even on the operator’s own residential property. Do not import another state’s homeowner exclusion or claim this definition treats every hand-dug hole the same way. Pennsylvania One Call is also a safety resource before any digging.

For ordinary covered excavation, the excavator submits the locate request at least THREE and no more than TEN BUSINESS DAYS before beginning. The notification day does not count; weekend or holiday notifications are processed on the following business day. Business days exclude Saturdays, Sundays and statutory legal holidays. Use the lawful start date for the actual request, not a generic seventy-two-hour countdown. Complex projects have a different minimum notice branch.

The actual excavator has the notice responsibility; hiring a contractor does not make an unrelated owner or contractor ticket interchangeable. The Act contains a specific limited delegation branch for work for a facility owner, municipality or municipal authority. Provide an exact work site and mark it in white when an exact description cannot be supplied.

Use due care, preserve facility markings and employ prudent locating techniques within the tolerance zone, which extends EIGHTEEN INCHES horizontally from the OUTSIDE WALL OR EDGE of the facility. Marks do not establish the precise depth, the property boundary or an easement. Owner-only service lines fall outside the facility-owner definition’s stated coverage and can require separate locating.

If clear site evidence shows an unmarked or incorrectly marked facility after a proper request, renotify One Call and follow the affected-area stop and response procedure. The Act has a conditional three-hour follow-up route, not general permission to ignore a visible line or start early. Renotification also applies when equipment is removed and the site vacated for more than two business days unless arrangements have been made with the affected owners, and when the location, scope or duration changes.

Immediately report damage, including coating or protective-system damage, to the facility owner. Escaping flammable, toxic or corrosive gas or liquid also requires immediate 911 notice and reasonable protective measures until the facility owner or emergency responders arrive and complete their assessment. Remain at the work site to convey pertinent information to responders. Genuine emergency excavation changes the ordinary notice timing but retains notification and safety duties. A utility ticket does not replace other approvals.

FARM BOUNDARY FENCES AND SHARED COSTS

The 1905 Fence Law, as amended says owners of improved and occupied land must erect and maintain equal portions of qualifying line or division fences. That text must be read with the Pennsylvania Supreme Court’s Fogle v. Malvern Courts, Inc. decision (1999). The Court explains that the law concerns farms and ranches and livestock containment, not typical single-family urban or suburban neighborhoods where livestock containment is not a concern.

A homeowner therefore cannot assume a neighbor owes half the price of a newly selected privacy fence just because it follows the line. Rural residential acreage can still raise the statute’s actual agricultural and livestock context. Existing private agreements, ownership and other enforceable restrictions are separate questions.

For a qualifying statutory dispute, the prescribed viewer is the COUNTY SURVEYOR; if the county has none, a surveyor of an adjoining county, or, after the stated refusal, a surveyor appointed by the court of common pleas. It is not automatically the township supervisors. The viewer examines sufficiency and, for an insufficient fence, reports the needed new work or repair and estimated cost to the specified judicial officer. The statute’s old justice-of-the-peace references are read as magisterial district judges under its compiler’s note.

The judicial notice gives the delinquent owner FORTY DAYS to do the specified work. Only after noncompliance does the statute provide for the aggrieved owner to do it and collect qualifying costs as a debt. No owner of improved land can be compelled under this provision to build or repair during DECEMBER, JANUARY, FEBRUARY or MARCH. The Act excludes railroad companies. These are statutory procedures, not authority to send any neighbor a unilateral invoice.

Where the viewer finds the complained-of fence sufficient, the complainant pays the viewer; for an insufficient fence, the delinquent owner pays. The statute limits the viewer’s charge to TWENTY-FIVE DOLLARS. Section 2 separately addresses later improvement and occupation up to an existing division fence, using a just-and-reasonable contribution considering its quantity, age and condition. Read that branch within the Fence Law’s applicable context rather than as a universal residential resale charge.

RESIDENTIAL SWIMMING POOLS AND SPAS

A yard fence used for pool safety must satisfy the applicable pool framework as well as ordinary zoning. Current 34 Pa. Code Section 403.26 directs a pool, hot tub or spa ACCESSORY TO A ONE-FAMILY OR TWO-FAMILY DWELLING to the 2021 International Swimming Pool and Spa Code. Its OTHER-THAN-ACCESSORY branch retains the Public Bathing Law and 2018 ISPSC. Shared, commercial or changed uses require their actual classification; do not transplant one branch into another.

The following describes the 2021 residential barrier baseline, subject to applicable Pennsylvania and lawful local provisions. The 2021 ISPSC barrier text distinguishes safety covers from ordinary covers: a spa or hot tub with a lockable ASTM F1346 safety cover, or a swimming pool with a powered ASTM F1346 safety cover, receives the stated relief from Sections 305.2–305.7. An ordinary tarp or manual pool cover is not that alternative. In-ground construction sites require fencing at least FOUR FEET high from excavation until the permanent barrier is completed.

Where a barrier is required, its top is at least FORTY-EIGHT INCHES above grade on the side AWAY FROM the pool, around the perimeter and for THREE FEET horizontally outside it. Bottom clearance is at most TWO INCHES over nonsolid ground, or FOUR INCHES over a solid surface, measured outside. A barrier mounted on the pool structure has a separate four-inch maximum gap above that structure. General openings must not pass a FOUR-INCH-DIAMETER sphere.

Climbability matters as well as height. Closely spaced horizontal members belong on the pool side and trigger smaller vertical gaps; solid barriers cannot provide the prohibited handholds or footholds. Chain-link and diagonal designs have their own one-and-three-quarter-inch opening limits. Mesh barriers have different installation, bottom-clearance and attachment requirements, and their inside face must be at least TWENTY INCHES from the water. Equipment outside the barrier on the same lot must be at least THIRTY-SIX INCHES from its outside face. Have the complete product and layout reviewed, rather than selecting by height alone.

Pedestrian doors and gates open OUTWARD, away from the pool, and must be self-closing, self-latching and capable of accommodating a lock. Unused utility or service gates stay locked; multiple-leaf gates have separate securing requirements. The 2021 latch rules distinguish outside-access non-self-locking releases, self-locking releases and the private-pool-only pool-side release. Do not carry over a universal latch-height rule from a different edition.

For residential barriers, an outside-access, non-self-locking release is at least FIFTY-FOUR INCHES above the finished floor or ground. A self-locking control has the stated no-greater-than-fifty-four-inch residential branch. At a private pool, a self-latching device whose ONLY release is on the pool side places it at least THREE INCHES below the gate top. Where an inside release is used, openings within EIGHTEEN INCHES of it may not exceed ONE-HALF INCH. These alternatives must be applied to the actual device and access arrangement.

A dwelling wall providing direct access can be part of the barrier only with the applicable alarms, qualifying cover or approved equivalent protection. A qualifying onground pool wall can serve as a barrier with the required height, manufacturer permission, compliant openings and secured, locked or removed access. Natural-shoreline and topography alternatives have their own conditions and approvals. They are not blanket exemptions for a pond-side pool or removable ladder.

The residential building-permit exception for a PREFABRICATED pool LESS THAN TWENTY-FOUR INCHES deep is separate. Section 403.62 does not add a five-thousand-gallon or entirely-above-ground condition to that particular exception. A permit exemption is not a general exemption from safety requirements. Confirm which existing-work, transition and local provisions apply to the actual pool and proposed replacement barrier.

ROADS, WATER, FLOODPLAINS AND SOIL DISTURBANCE

Public right-of-way can extend beyond pavement, shoulder or an existing fence. PennDOT’s right-of-way guidance identifies an unpermitted fence or wall within the legal highway right-of-way as an encroachment. Obtain the actual road boundary and responsible state or local authority’s requirements rather than assuming a statewide road width or measuring a private setback from the pavement.

A fence, solid base, wall or associated grading can affect water movement and protected access. Under 25 Pa. Code Chapter 105, regulated water obstructions and encroachments generally need prior written DEP authorization, subject to applicable waivers or other authorization. Streams, floodways, wetlands and other bodies of water have defined scopes. Not every dry-yard fence is a regulated obstruction, and an ordinary fence permit does not authorize work in protected waters.

The Flood Plain Management Act supports municipal floodplain regulation independently of a general zoning ordinance. Check the actual flood map, local development definition and applicable state waterway authority. A low or open fence is not automatically exempt; neither does the statewide framework itself supply one universal residential floodplain-fence design.

For ordinary construction-related earth disturbance, Chapter 102 requires erosion and sediment controls even below FIVE THOUSAND SQUARE FEET. A written plan is required at that threshold and under the other specified conditions, including certain potential discharges near High Quality or Exceptional Value waters. Construction stormwater permit requirements generally begin at ONE ACRE, including a qualifying larger common plan. These are different thresholds; a small project is not automatically free of all erosion duties. Agricultural activities have separate branches.

SPECIAL HOME USES AND ANIMAL ENCLOSURES

Certified family and group child-care homes have additional rules. Family-home outdoor-space rules and group-home rules require fencing or natural barriers where unsafe areas or conditions are in or near outdoor play space. These clauses do not give every ordinary residential play yard a fixed statewide fence height.

An in-ground pool accessible to children at these homes requires fencing with a LOCKED GATE. Unused aboveground pools must be inaccessible under the referenced CPSC barrier guidance, and unused indoor pools must be inaccessible. The family-home water rule and group-home water rule have distinct use and supervision contexts; group-home swimming pools also must conform to the public bathing-place chapter. These duties are additional to, not replacements for, the applicable construction and local rules.

For a dog covered by the dangerous-dog law, an ordinary yard fence may be insufficient. The enclosure regulation permits confinement inside the owner’s dwelling or in a securely enclosed and locked outdoor pen or structure designed to exclude young children and prevent escape. The outdoor enclosure needs secure sides, a secure top and weather protection. Without a floor secured to the sides, the sides must extend at least TWO FEET into the ground. These requirements do not apply to every household dog merely because it lives outdoors.

BOUNDARIES, PRIVATE RIGHTS AND TRESPASS NOTICE

An old fence, a permit and the legal boundary are different things. Confirm ownership and recorded access before moving a shared fence, attaching to it or entering neighboring land. Covenants, association declarations, easements and private agreements can operate separately from public approvals. A fence’s age or location alone does not decide title or extinguish a lawful access right.

Under 18 Pa.C.S. Section 3503, fencing or enclosure manifestly intended to exclude intruders can provide notice against trespass, subject to the offense’s knowledge and privilege conditions. Outside counties of the FIRST or SECOND CLASS, the purple-paint alternative uses vertical marks at least EIGHT INCHES long and ONE INCH wide, with their bottoms THREE TO FIVE FEET above ground, readily visible on approach and no more than ONE HUNDRED FEET apart. Paint does not establish a boundary, authorize an otherwise prohibited fence or defeat an existing right to enter.

HIRING A FENCE CONTRACTOR

The Home Improvement Consumer Protection Act expressly includes fence work at qualifying private residences when the agreed cash price is MORE THAN FIVE HUNDRED DOLLARS. Its contractor definition excludes a person whose total home-improvement cash value was LESS THAN FIVE THOUSAND DOLLARS in the previous taxable year, and has a separate large-retailer branch. New-home construction, unpaid owner work and certain other transactions are excluded. Registration coverage and project-price coverage are different tests.

Covered contractors must register with the Attorney General’s Bureau of Consumer Protection and put their registration number on the specified advertisements, contracts, estimates and proposals. Registration is not a fence permit, a survey or approval of workmanship. Applicable local building and trade requirements remain separate.

The contract must be legible and written, signed by the required parties, and include the entire agreement, date, contractor contact details, approximate start and completion dates, work and material specifications, price or a compliant time-and-materials provision, separately stated deposit and special-order amounts, known subcontractors, required insurance information and cancellation notice. A completed copy is due at signing. Changes to specifications require a written change order signed by owner and contractor.

A time-and-materials contract requires a written initial estimate and the stated ten-percent limit and potential-total disclosures; exceeding the estimate plus ten percent requires the signed change order. Payment cannot be demanded or received before the contract is signed. For contracts MORE THAN FIVE THOUSAND DOLLARS, the deposit generally cannot exceed ONE-THIRD of the contract price, plus separately designated special-order materials when applicable. The qualifying retailer letter-of-credit exception has its own conditions.

An individual signing a covered home-improvement contract generally may rescind WITHOUT PENALTY within THREE BUSINESS DAYS of signing, REGARDLESS OF WHERE it was signed, subject to the statutory emergency provisions. Do not reduce this right to only door-to-door sales. The Act separately regulates specified prohibited clauses, fraud and delayed-work refunds; it does not make every disagreement an automatic complete refund or authorize withholding every payment without regard to the contract and law.

USING THIS INFORMATION

This page provides general reference information about Pennsylvania laws that can affect residential fences. Updated November 2026. Each provision retains its own territorial, property, use and activity conditions.

It is not legal advice and does not replace controlling statutes, adopted regulations, court decisions, ordinances, permits, surveys, recorded documents or professional guidance. Public approvals and private property rights remain separate. Rules and interpretations may change; the controlling authorities govern.