Is Leaving a Knockout Open on a 4 Square Box a Code Violation?
Yes. Section 110.12(A) of the NEC states that unused openings, other than those intended for the operation of equipment, those intended for mounting purposes, or those permitted as part of the design for listed equipment, shall be closed to afford protection substantially equivalent to the wall of the equipment. An open half inch knockout on a 4 square box is an unused opening and it has to be closed.
Why the rule exists
Three reasons, and they all show up in the field. An open knockout lets a finger or a screwdriver reach energized parts, which defeats the enclosure. It gives an arc or a fire inside the box a path out into the wall cavity or the ceiling plenum. And in a damp or dusty location it lets water, insulation dust, and vermin in, which is how splices end up corroded or shorted years later.
The same requirement follows the equipment. Section 408.7 applies it specifically to panelboards and switchboards, and 312.5 covers cabinets and cutout boxes, requiring that conductors enter through openings that are closed around the cable or raceway. Article 314 handles boxes and conduit bodies, with 314.17 requiring openings through which conductors enter to be adequately closed.
What counts as closing it
A listed knockout seal or blank plug is the clean answer. They are stamped steel or plastic snap in closures sized to the standard knockout dimensions, and they are cheap enough that there is no reason to improvise. For a panel dead front, listed filler plates close unused breaker spaces, and 408.7 specifically requires the closure to be identified for the purpose. A breaker with the handle broken off, a piece of tape, or a scrap of sheet metal wedged in the hole is not a closure and will be written up.
Duct seal and spray foam are also not closures for this purpose. They may be required in addition to a closure where 300.7(A) calls for sealing a raceway that passes between areas at different temperatures, but they do not satisfy 110.12(A) on their own because they do not provide protection equivalent to the wall of the enclosure.
The exceptions worth knowing
Openings intended for the operation of equipment are exempt, which is why the handle slot on a panel dead front does not need to be plugged. Mounting holes are exempt, which is why the keyhole slots on the back of a box are fine. And openings permitted as part of the design for listed equipment are exempt, which covers ventilation louvers on a motor starter enclosure or a transformer can.
One more item that gets confused with this rule. A partially removed knockout, where the ring came off but the disc stayed, is not a closure. Neither is a knockout that broke unevenly and left a gap around a connector. If a connector does not fill the opening completely, use a reducing washer, sometimes called a chase nipple washer or reducer, which is listed for the purpose and closes the gap.
Field habit that saves callbacks: before the cover goes on, run a finger around the perimeter of every box and enclosure on the job. Open knockouts are one of the most common and most avoidable rough in corrections there is.