What building code actually requires for a stair
Stair dimensions are governed by building code far more tightly than most other framing elements, because inconsistent steps are a leading cause of falls. Most codes cap riser height around 7 3/4 inches and require a minimum tread depth around 10 inches, and — critically — every riser in a single flight has to be within about 3/16 inch of every other riser, since your foot expects the same step height every time. That consistency requirement is why stair math starts from total rise, not a target riser height: the calculator divides the total rise by the nearest whole number of risers that keeps each one code-compliant, rather than letting you pick a riser height that doesn't divide evenly. Headroom is often the constraint that gets missed on a retrofit: code typically requires at least 6 ft 8 in of clearance measured vertically from the nose of each tread, and framing a staircase without checking headroom against the floor structure above is one of the more common — and expensive — stair-building mistakes. Landing size and location also have minimums where a stair changes direction or exceeds a certain number of risers in one run, so long, steep stairs often can't be a single straight flight even if there's room for one.
How to calculate stairs
Stair design starts with the total rise — the vertical distance from the finished lower floor to the finished upper floor. Everything else is derived from it:
riserCount = round(totalRise ÷ targetRiser) ← never fewer than 2 riserHeight = totalRise ÷ riserCount ← every riser must match treadCount = riserCount − 1 ← upper floor is the "top tread" totalRun = treadCount × treadDepth stringer = √(totalRise² + totalRun²) angle = arctan(totalRise ÷ totalRun)
The IRC residential limits are 7.75 in max riser, 10 in min tread, 3/8 in max variation between any two risers or any two treads, and 6 ft 8 in minimum headroom. Comfort lives in a narrower band: 7 to 7.5 in risers paired with 10.5 to 11.5 in treads.
Common mistakes
- Measuring rise to the subfloor. Always measure to the finished floor surface — flooring thickness on the upper or lower level changes the top and bottom riser heights.
- Letting risers vary. Code allows 3/8 in variation between the largest and smallest riser in the run. Anything more is a trip hazard you will feel every time you walk it.
- Cutting all three stringers from one layout line. Slight saw drift compounds. Mark each stringer individually with a framing square and stair gauges, then test-fit before installing treads.
- Forgetting the top tread is the floor. Number-of-treads is always one less than number-of-risers. Buy treads accordingly or you will end up with an extra board.
