Stair Calculator

Free stair calculator. Compute riser height, tread depth, total run, and stringer length from total rise and number of steps — meets typical building codes.

Quick answer

Number of risers = total rise ÷ ideal riser height (~7 inches). Riser height = total rise ÷ number of risers. Tread depth = total run ÷ (risers − 1). The IRC allows risers up to 7-3/4" and treads at least 10" — your local code may be tighter.

Stair Calculator

Stringer layout

Number of steps
Riser height
Tread depth
Total run
Stringer length
Angle

How it works

Divides the total rise by your target step height, rounds to the nearest whole number of risers, then back-solves the actual riser height. Tread depth is calculated from the "rise + run = 17-18 inches" rule of thumb. Stringer length uses the Pythagorean theorem.

When to use it

Building a deck, basement stair, or porch landing. The IRC code allows max 7.75" risers and min 10" treads — the calculator targets 7.5"/10" for comfort.

Common mistakes

Inconsistent riser heights. The IRC requires all risers within a flight to be within 3/8" of each other, or you fail inspection. Always verify your floor-to-floor measurement is correct before cutting.

How the stair calculator works

The math starts with total rise (vertical distance, floor to floor) and total run (horizontal distance, the length of the stairs as seen from above). The calculator picks a number of risers that gets the per-riser height as close to 7 inches as possible while staying inside the 4-7-3/4 inch range allowed by the International Residential Code (IRC). Tread depth is total run divided by the number of treads — and there is always one fewer tread than riser because the top tread is the floor of the upper level.

Stringer length follows the Pythagorean theorem: stringer² = total rise² + total run². That is the diagonal length you cut to. Builders typically add 6-12 inches for waste and attachment to the upper and lower framing. The "rise + run" rule of thumb says rise + run should fall between 17 and 18 inches, and "2 × rise + run" should fall between 24 and 25 inches. Stairs that violate either rule feel awkward to climb.

When to use it

Use this calculator before cutting a stringer for a deck, basement, or interior staircase. Get the rise/run numbers right on paper before you commit to lumber — every stringer mistake costs a 2x12 in the trash. The calculator also helps when you are designing a stair within a tight horizontal footprint and need to know how many treads will fit before you buy lumber.

It is also useful for code checking. The IRC limits residential risers to 7-3/4 inches and requires treads of at least 10 inches. Many local codes are tighter — Chicago caps risers at 7 inches; California requires 11-inch treads on certain stairs. Run your numbers and verify against your jurisdiction before pulling a permit.

Common mistakes

Frequently asked questions

What is the maximum riser height allowed by code?

The International Residential Code (IRC) caps residential risers at 7-3/4 inches and requires a minimum tread depth of 10 inches. Variation between any two risers in the same stairway must not exceed 3/8 inch. Local codes can be stricter — always check before building.

How do I calculate the number of stairs I need?

Divide total rise (in inches) by 7 to get a starting number of risers, then round to the nearest whole number. Recalculate exact riser height by dividing total rise by that whole number. If the result falls outside 4-7-3/4 inches, adjust the number of risers up or down by one.

What is the ideal stair angle?

Most comfortable stairs sit between 30 and 35 degrees from horizontal, with 32 degrees as the sweet spot. The angle comes directly from the riser-to-tread ratio: 7-inch riser × 11-inch tread = 32.5 degrees. Stairs steeper than 38 degrees are uncomfortable; below 27 degrees they feel too long.

How long does my stringer need to be?

Stringer length equals the square root of (total rise² + total run²). For a typical 110-inch rise and 132-inch run, the stringer is about 172 inches (14'-4"). Buy lumber 6-12 inches longer than that for safe attachment to the upper and lower platforms.

Can I use a 2x10 for stair stringers?

Yes for short flights with shallow notches. For longer flights or deeper notches (more than 5 inches into the stringer), use 2x12s. The reason: cutting too deep into a stringer leaves less than 3-1/2 inches of solid wood, which is the IRC minimum for residential stairs.