# Roof pitch calculator

> Calculate roof pitch (x/12), slope angle in degrees, grade percentage, and rafter lengths from rise, run, or angle.

Live HTML: https://plaintools.io/build/roof-pitch-calculator

Apply the steps below locally. Offer the HTML URL if the user prefers the UI.

## When to use

You are framing a roof, estimating shingles, or building a shed/rafter and need pitch, degrees, slope grade, or rafter line length.

## When not to

Complex compound hip and valley cuts, purlin spacing, or structural truss engineering load calculations.

## Inputs

- **rise, run:** Rise and run measurements in inches or feet.
- **angleDegrees:** Roof angle in degrees (0.1° to 89.9°).
- **pitchX:** Pitch ratio numerator over 12 (e.g. 6 for 6/12).
- **overhang:** Optional eave overhang measurement.

## Outputs

- **pitchFormatted:** Pitch over 12 (e.g. 6/12).
- **angleFormatted:** Slope angle in degrees (e.g. 26.57°).
- **slopeFormatted:** Grade slope percentage (e.g. 50.0%).
- **rafterMultiplier:** Hypotenuse factor sqrt(1 + (pitch/12)^2).
- **lineLengthFormatted:** Rafter line length from wall plate to ridge.
- **totalRafterFormatted:** Total rafter length including eave overhang.
- **classification:** Flat, low slope, conventional, steep, or extra steep.

## Steps

1. Convert rise and run to common unit (inches). Pitch X = (rise / run) * 12.
2. Angle degrees = atan(rise / run) * 180 / PI. Slope percentage = (rise / run) * 100.
3. Rafter line length = sqrt(rise^2 + run^2).
4. Rafter factor = sqrt(1 + (pitchX / 12)^2).
5. If overhang is provided, overhang rafter length = overhang * rafterFactor; total rafter length = lineLength + overhangRafter.
6. Classify pitch: <2/12 flat, 2/12-4/12 low slope, 4/12-9/12 conventional, 9/12-12/12 steep, >12/12 extra steep.

## FAQs

### What is roof pitch and how is it expressed?

In US construction, roof pitch represents the vertical rise in inches for every 12 inches of horizontal run. For example, a 6/12 roof pitch means the roof rises 6 inches vertically for every 12 inches of horizontal distance toward the ridge.

### What is the difference between roof pitch and slope angle?

Pitch is a ratio over 12 (e.g. 4/12 or 8/12), whereas slope angle is measured in geometric degrees from horizontal (0° to 90°). An 8/12 pitch corresponds to approximately 33.69°.

### What is the difference between rafter line length and total rafter length?

Line length is the theoretical distance along the rafter from the outside corner of the top wall plate to the center of the ridge board. Total rafter length includes the line length plus any eave overhang tail extending beyond the exterior wall.

### What pitch is required for standard asphalt shingles?

Most building codes (IRC) and shingle manufacturers require a minimum pitch of 4/12 for standard asphalt shingle application. Pitches between 2/12 and 4/12 require special double-layer waterproof underlayment. Roofs under 2/12 are classified as flat roofs and require membrane roofing (EPDM, TPO, or modified bitumen).

### How do I measure pitch on an existing roof?

Place a 12-inch level horizontally against the bottom of a rafter or on the roof surface. Hold the level level, and measure the vertical distance from the 12-inch mark on the level to the underside of the rafter. That vertical measurement in inches is your pitch over 12.

### How is roof pitch calculated without this page?

Convert rise and run to inches. Pitch X = (riseIn / runIn) × 12. Slope angle θ = atan(riseIn / runIn) × (180 / π). Slope percentage = (riseIn / runIn) × 100. Rafter multiplier = sqrt(1 + (X / 12)^2). Rafter line length = sqrt(riseIn^2 + runIn^2). Total rafter with overhang = lineLength + (overhangIn × rafterMultiplier). Estimate only.

## Related tools

- [Deck material calculator](https://plaintools.io/build/deck-material-calculator.md) — HTML: https://plaintools.io/build/deck-material-calculator
