If you're replacing an existing fixture, switch, or receptacle,
there's usually no need to contact the building department. But
when you run new electrical cable for new service, whether
wiring several circuits or adding just one receptacle, be sure
to work with a building inspector and comply with all local
codes. National and local codes Professional electricians often
refer to the National Electrical Code (NEC), a massive volume
that describes national codes for residential and commercial
wiring. You don't need to buy this book, but you may need to
refer to a library copy from time to time. Local building
departments often modify the NEC, and you must satisfy those
local codes. It's not unusual for adjacent towns to have very
different codes; for instance, one may allow plastic boxes while
another requires metal boxes. Have a local inspector approve
your wiring plans before you begin work. If existing wiring does
not meet local codes, chances are that your building department
will not require you to change