Roof Pitch Calculator
Convert roof rise and horizontal run into rafter length, slope angle, percent grade, x:12 pitch, and pitch factor.
The startup example is ready to export.
Roof dimensions
Live results
Equivalent pitch formats
| Format | Current value | Interpretation |
|---|---|---|
| Angle | 14.04° | Rafter angle above horizontal |
| Percent grade | 25.00% | 25 units of rise per 100 units of run |
| x:12 ratio | 3.00:12 | 3 units of rise per 12 units of run |
| Pitch factor | 1.0308 | Sloped length per unit of horizontal run |
How to use this roof pitch calculator
What this calculator does
This calculator treats one side of a roof as a right triangle. From the vertical Rise and horizontal Run length, it calculates the sloped Rafter length, the roof angle in degrees, the slope as a percentage, the familiar x:12 ratio, and the pitch factor. It is useful for checking measurements, comparing pitch notations, estimating a basic rafter line, and translating plans that use different unit systems. It does not determine structural member size, bearing capacity, snow or wind design loads, fastening, overhang, ridge cuts, birdsmouth cuts, or code compliance.
When to use it
Use it while measuring an existing roof, checking a preliminary roof sketch, converting a contractor's 6:12 description into degrees, or estimating the diagonal length before adding overhang and cut allowances. For work at height, follow recognized fall-protection practices; the OSHA fall-protection guidance explains why roof access requires proper planning and equipment.
How to calculate
- The calculator opens with a ready-to-use example: a 1.5 m rise and 6 m run. Its results and a validated Excel workbook are available immediately.
- Replace Rise with the vertical distance from the eave or wall-plate level to the ridge. Choose the unit beside the field.
- Replace Run length with the horizontal distance from the outside wall line to the ridge, not the sloped roof surface. Choose its unit independently.
- Choose the Output length unit for the rafter result. This changes only the displayed/exported length, not the slope.
- Read the live result cards and the equivalent-format table. Select Download Excel to export the current inputs and results.
- Select Reset to clear the demonstration values and calculated state. Excel export is then disabled until complete valid rise and run values are entered again.
Input guide
Rise is required and accepts a positive decimal number using a period as the decimal separator, such as 1.5. Its unit may be meters, centimeters, feet, or inches. A larger rise with the same run makes the roof steeper, increases the angle and x:12 value, and lengthens the rafter. Do not enter a signed value, a fraction such as 6/12, scientific notation, or a measurement that already includes the sloped rafter.
Run length is required and also accepts a positive decimal number, such as 6. It is the horizontal projection for one roof side. A longer run with the same rise makes the pitch shallower while increasing the rafter length. For a symmetrical gable roof, the run is normally half the clear span only when the ridge is centered and wall assumptions match the drawing. Do not substitute total building width without checking that geometry.
Output length unit is a required display control, not a new measurement. Choose meters, centimeters, feet, or inches. Changing it converts the rafter result and workbook values while preserving the same physical length. For precise project documentation, use consistent units; the NIST overview of SI length units provides context for metric measurement.
Output guide
Rafter length is the hypotenuse of the right triangle formed by rise and run. It is an exact geometric identity for the entered dimensions, but a real cut length may need overhang, ridge-board, seat-cut, and connection allowances. Roof pitch is the angle above horizontal in degrees. Roof pitch (%) is rise divided by run, multiplied by 100. Roof pitch (x:12) reports how many units the roof rises for every 12 horizontal units. Pitch factor is rafter length divided by run; multiplying a horizontal roof-plan area by this factor gives a simple single-plane sloped-area conversion when the plan geometry is appropriate. Pitch category is a broad descriptive band, not a code ruling or product-eligibility decision.
Worked example
With a rise of 1.5 m and a run of 6 m, the rafter length is found from the Pythagorean theorem: √(1.5² + 6²) = √38.25 = 6.1847 m, displayed as 6.185 m. The slope ratio is 1.5 ÷ 6 = 0.25, so the percent grade is 25.00%. The angle is arctan(0.25) = 14.04°. Multiplying 0.25 by 12 gives 3.00:12, and dividing 6.1847 by 6 gives a pitch factor of 1.0308. These are the exact first-open values used by the calculator and workbook.
Formula and planning notes
rafter = √(rise² + run²) · angle = arctan(rise ÷ run) · percent = 100 × rise ÷ run · x:12 = 12 × rise ÷ run
All input lengths are converted internally to meters before calculation, so mixed units are valid. The ratio, angle, percent, and pitch factor are dimensionless and therefore do not change when length units change. A roof close to flat still needs drainage design, waterproofing, and detailing; a steep roof may require specialized access, fastening, and structural review. Energy performance also depends on surface color, insulation, ventilation, climate, and assembly details. The U.S. Department of Energy's cool roof guidance discusses roof-surface choices separately from pitch geometry.
Before ordering materials or cutting rafters, verify field dimensions, overhang, ridge details, local building requirements, and the roofing manufacturer's minimum-slope instructions. For structural or safety-critical work, use drawings and calculations prepared or reviewed by a qualified professional.