Roof Pitch Formula
Divide vertical rise by horizontal run, then multiply by 12 to write roof pitch as x:12. To check it, use that pitch and the same horizontal run to recover the original rise.
Calculate and reverse-check one pair
Same triangle, forward and back
Forward formula: rise and run to x:12
For the angle between the roof line and the horizontal, a right triangle uses tangent as opposite divided by adjacent.1 In this roof-geometry model, label vertical rise as the opposite leg and horizontal run as the adjacent leg. The ratio is rise ÷ run.
To write that ratio in x:12 notation, use pitch rise = (rise ÷ run) × 12. For an original example with 5 units of rise and 20 matching units of horizontal run: (5 ÷ 20) × 12 = 3, so the pitch is 3:12. The same ratio gives 25% and atan(5 ÷ 20) ≈ 14.036°.
Reverse formula: pitch and run to rise
To reverse the x:12 notation, use rise = horizontal run × pitch rise ÷ 12. The same example returns 20 × 3 ÷ 12 = 5 units. Recovering the starting rise is a simple check that the forward and reverse calculations describe the same triangle.
Keep rise and horizontal run in the same length unit before forming the ratio. NIST identifies the metre as the SI base unit for length and documents SI prefixes, including milli; that makes millimetres and metres length records that must be brought to one unit before the arithmetic pair is entered.2
Can I use a roof pitch formula if my measurements use different units?
Yes—convert one measurement so rise and horizontal run use the same length unit before calculating. For example, do not divide a rise recorded in inches by a run recorded in feet as if the values already share a unit. After conversion, calculate the ratio and reverse-check it against the same converted pair.
What the formula does not decide
This formula describes a right-triangle geometry check. It does not specify framing cuts, member sizing, roof-covering selection, drainage performance, or project requirements. Keep those decisions in their own project documentation and source them separately.
Sources
- OpenStax, “Right Triangle Trigonometry” — defines tangent as opposite divided by adjacent in a right triangle.
- National Institute of Standards and Technology, “SI Units” — describes the SI system, its base units, and prefixes.
The diagrams and examples are original geometry explanations. They are not construction drawings or approvals.