Stair Calculator
Find the number of steps, riser height, tread depth, and stringer length for your staircase from total rise — with IRC code-compliance checks.
Last updated July 28, 2026
How to use the stair calculator
- 1
Measure your total rise — the exact vertical distance from finished floor to finished floor.
- 2
Enter your target riser height and tread depth.
- 3
Your number of risers and treads, actual riser height, total run, stringer length, angle, and code-compliance checks update instantly.
How stair dimensions are calculated
Stair math starts with total rise — the exact vertical floor-to-floor height — because unlike most other dimensions, it can't be adjusted. Everything else is solved around it:
- Number of risers = round(total rise ÷ target riser height)
- Actual riser height = total rise ÷ number of risers — always a little different from your target, since the total rise rarely divides in evenly
- Number of treads = number of risers − 1, since the top floor itself serves as the final step
- Total run = number of treads × tread depth
- Stringer length = √(total rise² + total run²) — the Pythagorean theorem applied to the overall stair triangle
- Stair angle = atan(total rise ÷ total run), converted to degrees
Worked example: A total rise of 108 inches (9 ft) with a 7.5-inch target riser gives 108 ÷ 7.5 = 14.4, which rounds to 14 risers. The actual riser height becomes 108 ÷ 14 = 7.71 inches. With 13 treads at 10 inches each, total run is 130 inches, and the stringer works out to √(108² + 130²) ≈ 169 inches — about 14.1 ft of raw stringer board.
Framing a staircase into a deck project? Our Deck Material Calculator covers the boards, joists, and footings for the deck itself.
Stair building code basics
Most U.S. residential stair rules trace back to the International Residential Code (IRC), though local jurisdictions can adopt stricter amendments — always confirm with your local building department before finalizing a design.
| Element | Typical IRC limit |
|---|---|
| Maximum riser height | 7¾" (196 mm) |
| Minimum tread depth | 10" (254 mm) |
| Riser height variance within a flight | ⅜" (9.5 mm) max between largest and smallest |
| Minimum headroom | 6'8" (80" / 2032 mm) |
| Minimum stair width | 36" (914 mm) |
Because this calculator spreads the total rise evenly across a whole number of risers, the riser-height-variance rule is always satisfied automatically — every riser in the flight comes out identical. The compliance checks shown in your results cover riser height, tread depth, and comfortable angle only; headroom and stair width depend on your framing and floor plan and should be verified separately.
Tackling another safety-sensitive home project? Our Garage Door Spring Calculator → estimates torque, winding turns, and a suggested size range for torsion or extension springs.