
The maths behind a stair rail calculator
A handrail runs parallel to the pitch line of your stairs, the imaginary line connecting the nosing of every step. To find its length, you use the same rise and run figures you would use for stringer layout, but apply the Pythagorean theorem to find the hypotenuse rather than the individual step dimensions. Total rise squared plus total run squared, then square root the result, gives you the sloped length of the stair itself, and the handrail is typically cut a little longer than this to allow for the newel post connections at each end.
For a 13-step flight with 7.5 in (19 cm) risers, total rise is 97.5 in (247.7 cm). With 10 in (25 cm) treads across 12 tread spaces (one fewer than the step count, since the top step is the landing), total run is 120 in (305 cm). The pitch line length works out to the square root of 97.5 squared plus 120 squared, which is approximately 154.6 in (392.7 cm), or 12.9 ft (3.93 m). Add roughly 6-12 in (15-30 cm) at each end for post connections, and your handrail material should be around 13.5-14.5 ft (4.1-4.4 m).
Working out the rail angle
The rail angle, or pitch angle, is found using the arctangent of rise over run. In our example, that is the arctangent of 97.5 divided by 120, which comes out to approximately 39.1 degrees. This is the angle at which the handrail brackets need to be cut and the angle a carpenter will use to mitre the rail ends where they meet the newel posts. Most residential stairs fall between 30 and 42 degrees, with steeper stairs common in older homes and shallower pitches favoured in modern new-builds for comfort.
| Measurement | US (in/ft) | UK (cm/m) |
|---|---|---|
| Total rise | 97.5 in | 247.7 cm |
| Total run | 120 in | 305 cm |
| Pitch line length | 12.9 ft | 3.93 m |
| Handrail with allowance | 13.5-14.5 ft | 4.1-4.4 m |
| Pitch angle | 39.1 deg | 39.1 deg |
Know your numbers in 30 seconds
Enter your step count, tread depth and riser height — the stair runner calculator gives you the exact length to order, in metres and feet, with waste included.
Open the stair runner calculatorWhy runner length matters alongside rail length
While the handrail calculation uses the hypotenuse of the full rise and run, the stair runner calculation is different because it needs to account for the tread and riser separately, plus the nosing wrap at every step, rather than a straight diagonal line. This is why a 13-step flight needs around 23-24 ft (7-7.3 m) of runner, noticeably more than the 13-14.5 ft (4-4.4 m) needed for the handrail, even though both are measuring the same physical staircase.
Per step: 10 in tread + 7.5 in riser + 0.75 in nosing wrap = 18.25 in (46.4 cm). Across 13 steps that is 237.25 in (602.6 cm), plus a 24 in (60 cm) finishing allowance top and bottom, totalling 261.25 in (663.6 cm), or 21.77 ft (6.64 m). With a 10% waste margin, order approximately 24 ft (7.3 m).
Rail and runner projects often happen together
If you are replacing a handrail, it is a good opportunity to also refresh your stair runner, since both jobs typically require the stairs to be clear of foot traffic for a similar period.
Choosing rail material and hardware
Timber handrails remain the most common choice in both the US and UK, typically in oak, pine or maple, with a moulded profile for a comfortable grip. Metal rails, including wrought iron and brushed steel, are popular in more contemporary homes and require slightly different bracket spacing since the material flexes less than timber over long spans.
Bracket spacing on a handrail generally follows a maximum of 4 ft (1.2 m) between supports for timber, tightening to 3 ft (91 cm) on rails over 10 ft (3 m) long to prevent flex. Always check your local building code for exact requirements, as both US and UK regulations set minimum handrail heights, typically 34-38 in (86-97 cm) above the nosing line.
- Use rise and run with the Pythagorean theorem to find pitch line length.
- Add extra length at each end for newel post connections.
- Use arctangent of rise over run to find the cutting angle.
- Calculate runner length separately using the per-step formula.
- Check local code for minimum handrail height and bracket spacing.
Bringing it together
Once you have both your rail and runner numbers, you have a complete material list for a stair refresh. Use the stair runner length calculator to fine-tune your carpet order, and keep your rail angle handy for whoever is cutting or installing the new handrail.

Worked example in full metric and imperial
It helps to see both unit systems side by side on the same staircase. In US units: 97.5 in total rise, 120 in total run, gives a pitch line of the square root of (97.5 squared + 120 squared) = square root of (9506.25 + 14400) = square root of 23906.25 = 154.6 in, or 12.9 ft. In metric: 247.7 cm rise, 305 cm run, gives the square root of (247.7 squared + 305 squared) = square root of (61354.3 + 93025) = square root of 154379.3 = 392.9 cm, or 3.93 m, matching the imperial figure once converted. Keeping both unit systems consistent throughout the calculation avoids the small rounding errors that creep in if you mix inches and centimetres partway through.
Handrail cost bands
Handrail material and installation costs vary widely by material choice. A basic pine handrail with standard brackets typically costs $8-15 per linear ft ($26-50/m) installed in the US, or £18-30 per linear metre in the UK. Oak or hardwood rails with a moulded profile run $18-30 per linear ft (£40-65/m), while custom wrought iron or forged steel rail systems can reach $40-80 per linear ft (£90-170/m) once fabrication and fitting are included. Expect to pay a call-out or minimum job fee on top of the linear rate for most short residential rail replacements.
| Rail type | US installed | UK installed |
|---|---|---|
| Basic pine | $8-15/ft | £18-30/m |
| Oak/hardwood moulded | $18-30/ft | £40-65/m |
| Wrought iron/steel | $40-80/ft | £90-170/m |
Checking your numbers before ordering material
Before cutting any rail stock, physically measure the pitch line on site with a string line or laser, and compare it against your calculated 12.9 ft (3.93 m) figure. Small discrepancies of half an inch or so are normal and come from real-world variances like out-of-square newel posts, but anything larger suggests a measurement or arithmetic error worth rechecking before you commit to an expensive length of hardwood or metal rail stock.
- Recalculate the pitch line using the Pythagorean theorem with your own on-site rise and run.
- Keep units consistent throughout, do not mix inches and centimetres mid-calculation.
- Compare calculated length against a physical string-line check on site.
- Budget for a call-out or minimum job fee on short rail replacement jobs.
- Choose bracket spacing based on material stiffness, tightening on longer unsupported spans.
Whatever you decide, get the numbers first: the stair runner calculator doubles as a stair runner length calculator, adding nosing wrap, landings, winders, pattern repeat and waste so you order the right length the first time.
Still deciding on material, width or pattern? Our hub on stair runners compares weaves, widths, backings and fitting styles side by side, then hands the numbers straight to the calculator.
Frequently asked questions
How is handrail length calculated?
By taking the square root of total rise squared plus total run squared, then adding an allowance for newel post connections.
What is a typical stair pitch angle?
Most residential stairs fall between 30 and 42 degrees, calculated as the arctangent of rise over run.
Does the handrail calculation include the nosing wrap?
No, that only applies to runner length. Handrail length uses the straight pitch line distance.
How much extra should I add to my handrail length?
Typically 6-12 in (15-30 cm) at each end to allow for connections at the newel posts.
What is the minimum legal handrail height?
Usually 34-38 in (86-97 cm) above the nosing line, though you should confirm with your local building code.
How far apart should handrail brackets be?
Generally no more than 4 ft (1.2 m) apart for timber rails, tightening on longer spans.
Do I need to replace my runner when I replace my handrail?
Not necessarily, but it is a convenient time to do both since the stairs are already clear for work.
Can I use the same calculator for rail and runner?
No, use a dedicated stair rail calculator for the handrail and a stair runner calculator for the carpet, since the formulas differ.
Know your numbers in 30 seconds
Enter your step count, tread depth and riser height — the stair runner calculator gives you the exact length to order, in metres and feet, with waste included.
Plan your stairs with the stair runner calculatorEvery guide is written from hands-on measuring and fitting experience, checked against the calculator’s own maths, and re-reviewed whenever prices or methods change. Read our editorial standards.