Outlet Spacing Calculator Formula
Understand the math behind the outlet spacing calculator. Each variable explained with a worked example.
Formulas Used
Outlets Needed
outlets_needed = max_spacing > 0 ? ceil(wall_length / max_spacing) + num_doors : 0Actual Spacing
actual_spacing = max_spacing > 0 && (ceil(wall_length / max_spacing) + num_doors) > 0 ? wall_length / (ceil(wall_length / max_spacing) + num_doors) : 0Variables
| Variable | Description | Default |
|---|---|---|
wall_length | Total Wall Length(ft) | 40 |
max_spacing | Max Spacing(ft) | 12 |
num_doors | Number of Doorways | 2 |
How It Works
NEC Outlet Spacing (210.52)
The NEC requires that no point along a wall be more than 6 feet from an outlet. This effectively means outlets every 12 feet along unbroken walls. Each wall section separated by a door counts independently. Kitchens and bathrooms have additional requirements.
Worked Example
40 ft of total wall length with 2 doorways, 12 ft max spacing.
wall_length = 40max_spacing = 12num_doors = 2
- 01Base outlets = ceil(40 / 12) = 4
- 02Add 1 per doorway = 4 + 2 = 6 outlets
- 03Actual spacing = 40 / 6 = 6.7 ft apart
Ready to run the numbers?
Open Outlet Spacing Calculator