Drainage Slope Calculator (Code-Compliant)
Calculate minimum drain pipe slope and total fall from IPC/UPC code thresholds — verify rough-in drop, check installed slope compliance, and see pass, fail, or steep-slope caution badges update live as you adjust diameter, run length, or pitch.
Drain Run Details
Live Results
Total Fall Required
2.5 in
Code target: 1/4 in/ft (2%) minimum for 3" drain pipe per IPC/UPC.
Code Target
1/4 in/ft (2%)
Pipe Diameter
3"
Run Length
10 ft
Min Slope
0.25 in/ft
Minimum slopes per IPC/UPC: 1/4 in/ft for 1-1/4" through 3" drain pipe; 1/8 in/ft for 4" and larger. Verify local amendments before installation.
How to Use This Drainage Slope Calculator
- Select pipe diameter. Choose the nominal drain pipe size from the dropdown — 1-1/4" through 6". IPC and UPC both require 1/4 in/ft minimum slope for pipes up through 3", and 1/8 in/ft for 4" and larger.
- Enter pipe run length. Input the horizontal run length in feet — the distance from the upstream fixture or cleanout to the downstream connection, measured along the pipe centerline on the horizontal plane. Run length also affects steep-slope warnings on long installations.
- Optionally select installed slope. If you know the slope you plan to install, pick it from the Actual Slope Installed dropdown (1/16 through 1/2 in/ft). Leave it on "Use code minimum" to see the required total fall without a compliance check. When a slope is selected, the calculator evaluates it against the code minimum for your pipe size.
- Review total fall and compliance badge. Results update instantly as you change any input. Total fall shows the drop in inches — from the code minimum when no slope is selected, or from your chosen slope when one is active. The badge shows one of four states: an informational code target (no slope selected), red fail (slope below minimum), yellow caution (slope above 1/2 in/ft on a run over 20 ft), or green pass (meets or exceeds the code minimum in all other valid cases).
Formulas & Example
Total fall equals slope (inches per foot) multiplied by horizontal run length (feet). Code minimum slope depends on pipe diameter.
Total Fall (in) = Slope (in/ft) × Run Length (ft)
IPC/UPC minimum slopes:
1-1/4" through 3" pipe: 1/4 in/ft (0.25 in/ft, 2%)
4" and 6" pipe: 1/8 in/ft (0.125 in/ft, 1%)
Compliance badges (when installed slope is selected):
Fail (red): Installed Slope < Code Minimum Slope
Caution (yellow): Installed Slope > 0.5 in/ft AND Run Length > 20 ft
Pass (green): All other valid states (meets or exceeds code minimum)Worked Example — Code Minimum
3" drain pipe, 12 ft horizontal run, code minimum slope of 1/4 in/ft:
Min Slope = 0.25 in/ft
Total Fall = 0.25 × 12 = 3.00 in
Result: 3.00 in drop required over 12 ft run (informational code target)Worked Example — Fail & Pass
Same 3" pipe and 12 ft run with an installed slope selected:
1/8 in/ft installed: 0.125 < 0.25 → Fail (red)
Total Fall = 0.125 × 12 = 1.50 in
1/4 in/ft installed: 0.25 ≥ 0.25 → Pass (green)
Total Fall = 0.25 × 12 = 3.00 in
1/2 in/ft installed: 0.5 ≥ 0.25, run ≤ 20 ft → Pass (green)
Total Fall = 0.5 × 12 = 6.00 inWorked Example — Steep Slope Caution
A slope strictly above 1/2 in/ft on a run longer than 20 ft triggers the yellow caution even when the code minimum is met:
3" pipe, 25 ft run, 0.625 in/ft installed (> 0.5 in/ft):
Min Slope = 0.25 in/ft → code minimum met
0.625 > 0.5 AND 25 > 20 → Caution (yellow)
Total Fall = 0.625 × 25 = 15.63 in
Same 0.625 in/ft on a 15 ft run → Pass (green); run length ≤ 20 ftFrequently Asked Questions
What is the minimum slope for drain pipe per IPC/UPC?▾
How do I calculate total fall for a drain run?▾
Can drain pipe slope be too steep?▾
What do the compliance badge colors mean?▾
Does 3-inch pipe require 1/4 or 1/8 inch per foot slope?▾
Should I verify slope against local code amendments?▾
Related Tools
- Pipe Sizing & Pressure Drop Calculator
- Water Flow Rate Calculator (PSI → GPM)
- Hot Water Tank Sizing Calculator
- Gutter & Downspout Length Calculator
Browse all Plumbing calculators · Full directory