How to Use the Roof Pitch Calculator
Enter the roof measurements, choose a unit for each field, and click Calculate.
- Enter Rise (vertical height), the vertical height the roof climbs.
- Enter Run (horizontal distance), the horizontal distance from the wall plate to the ridge center line. For a simple gable, this is often half the building span.
- Enter Overhang (optional), the horizontal eave extension beyond the wall. Use
0when there is no overhang; the field must still contain a number. - Choose
in,ft,cm, ormindependently for each field. - Click Calculate to show the result. Use Copy result for a plain-text summary or Download result (.txt) to save a plain-text file.
- Click Reset to restore rise
6 in, run12 in, overhang0 in, and inches in all selectors. Reset also hides the result.
What the Result Shows
The headline values show roof pitch as X/12, roof angle from horizontal, slope grade percent, and rafter length. The headline rafter length is shown in feet. The result table lists entered values, inch conversions, pitch, angle, slope, and common-rafter lengths in feet and inches.
A single combined formula block appears above the table; the table does not show a separate formula for every row. Copy result copies the plain-text summary, and Download result (.txt) saves it as a text file.
Formulas and Overhang
The calculator normalizes each entered unit to inches internally. It then applies these formulas:
Roof pitch (X/12) = (Rise / Run) x 12Angle = atan(Rise / Run)Slope % = (Rise / Run) x 100Rafter length = sqrt(Rise^2 + (Run + Overhang)^2)
Overhang is added to the run, not the rise, before the rafter length is calculated.
Validation and Calculation Limits
Rise must be a number from 0.01 through 600 in its selected unit. Run must be from 0.01 through 1200. Overhang must contain a number from 0 through 240 in its selected unit. Invalid input stops the calculation and shows an error instead of a result.
- The result is a theoretical straight common-rafter length.
- It does not account for ridge board thickness, birdsmouth or seat cuts, hip or valley rafters, snow or wind load, lumber sizing, material quantities, or building-code requirements.
- Displayed and exported values are formatted to fixed decimal places.
Calculation Privacy Note
The calculator JavaScript performs calculations from the values you enter locally. Its calculation code does not send those inputs through its own calculation process. The page also includes analytics, server-side tool-hit recording, and an optional server-backed subscription form.
Frequently Asked Questions
What is the roof pitch formula?
Roof pitch (expressed as X/12) = (Rise / Run) x 12, where rise and run are measured in the same unit. For example, a 6 in rise over a 12 in run is a 6/12 pitch. The roof angle from horizontal is atan(Rise / Run), and the common rafter length is sqrt(Rise^2 + Run^2).
What do rise and run mean for a roof?
Run is the horizontal distance from the outside wall to the center of the ridge (typically half the building span for a simple gable). Rise is the vertical height the roof climbs over that same run. Roof pitch is conventionally expressed as inches of rise per 12 inches of run, e.g. a 4/12 or 8/12 pitch.
How is rafter length calculated, and what does overhang do?
The common rafter length is the hypotenuse of the rise and run: sqrt(Rise^2 + Run^2). If you enter an overhang (the horizontal eave extension beyond the wall), the calculator adds it to the run before finding the hypotenuse, giving a rafter length that includes the overhang. This is a straight-line theoretical length - it does not subtract for ridge board thickness, birdsmouth cuts, or seat cuts, which a carpenter accounts for separately when cutting actual lumber.
What units are supported?
Rise, run, and overhang each accept inches, feet, centimeters, or meters, chosen independently for each field.
Does this tool fetch live data or give certified advice?
No. It performs a single, transparent calculation using only the values you type in. It does not fetch building-code tables, span tables, or supplier data, and it is not a certified structural, engineering, or building-code determination.