How to calculate roof pitch, angle and rafter length
Roof pitch is how many inches a roof rises for every 12 inches it runs horizontally. A 6-in-12 roof, written 6/12, climbs 6 inches for each foot of level distance. Once you know the pitch, the other numbers a framer or roofer needs follow from a little geometry: the angle, the rafter lengths and the area you have to cover.
This guide shows how to measure pitch, convert it, and use it for rafters and materials, with worked examples you can check by hand.
How to measure rise and run
Pitch is a ratio, so you only need two measurements in the same unit. The run is always level distance, not distance along the roof surface. Measuring in the attic, under a gable-end rafter, is usually safer than climbing onto the roof.
- Mark a point 12 inches from one end of a level.
- In the attic, touch that end of the level to the bottom edge of a rafter, extend the level toward the ridge and hold it perfectly level.
- Measure straight up from the 12-inch mark to the rafter. That distance is the rise for a 12-inch run.
- If you measured over a different run, scale it: rise ÷ run × 12. A 9-inch rise over an 18-inch run is 9 ÷ 18 × 12 = 6, so the pitch is 6/12.
On a symmetrical gable, the run of each rafter is half the span, the building’s width measured across the outside of the walls. A ridge 4 feet above the wall plates with a 12-foot run is a 4/12 roof.
Convert pitch to an angle and a percent grade
The same slope can be written three ways. Pitch is rise in 12. Percent grade is rise ÷ run × 100. The angle in degrees is the arctangent of rise ÷ run, shown as tan⁻¹ on a scientific calculator.
- 3/12: 14.0°, 25% grade, slope factor 1.031
- 4/12: 18.4°, 33.3% grade, slope factor 1.054
- 6/12: 26.6°, 50% grade, slope factor 1.118
- 8/12: 33.7°, 66.7% grade, slope factor 1.202
- 12/12: 45.0°, 100% grade, slope factor 1.414
The slope factor is the square root of 1 + (rise ÷ run)². Multiply any level distance by it to get the matching distance along the slope. Metric works the same way: a roof that rises 50 cm over a 100 cm run is a 50% grade, 26.6°, the same as 6/12.
Calculate common rafter length
A common rafter runs from the wall up to the ridge, square to both. Its length along the slope is its run times the slope factor.
- Find the run: half the span. For a building 24 feet wide, the run is 12 feet, or 144 inches.
- Take off half the ridge board’s thickness for ridge shortening. With a 1½-inch ridge board, subtract ¾ inch: 143.25 inches.
- Multiply by the slope factor. At 6/12, 143.25 × 1.118 = about 160.2 inches, roughly 13 ft 4 in. This is the theoretical line length before you lay out the seat cut and tail.
- Add the overhang. A 12-inch level overhang at 6/12 adds 12 × 1.118 = 13.4 inches along the slope.
Without the ridge shortening, the full 12-foot run gives 13.42 feet, about 13 ft 5 in, so skipping that step makes every rafter about 0.84 inch too long.
Hip and valley rafters use the 45-degree diagonal
On a regular hip roof, where both slopes share the same pitch, the hip rafter crosses the corner at 45 degrees in plan. For every 12 inches the common rafters run, the hip runs 12 × √2, about 16.97 inches, for the same rise, which is why hip slope is described per 17 inches.
Example: a 6/12 roof with a 12-foot common run rises 6 feet. The hip’s plan run is 12 × 1.4142 = 16.97 feet, so its length is √(16.97² + 6²) = √324 = 18 feet, before the ridge shortening and tail adjustments. Its slope is about 19.5 degrees, shallower than the 26.6-degree common rafters. A valley rafter between two equal-pitch roofs follows the same diagonal.
Estimate roof area and shingles
For a roof with one pitch throughout, the sloped area is the plan area, the footprint including overhangs, times the slope factor. Roofing is usually estimated and sold by the square, which covers 100 square feet.
- Plan area including overhangs: 30 × 40 feet = 1,200 square feet.
- Sloped area at 6/12: 1,200 × 1.118 = 1,341.6 square feet, or 13.42 squares.
- Add waste for cuts, starter rows, hips and ridges. At 10%, that is 14.76 squares.
- Convert to bundles. Many common asphalt shingles come three bundles to the square: 14.76 × 3 = 44.3, so order 45 bundles. Check the coverage printed on the wrapper.
A plain gable needs less waste than a roof cut up by hips, valleys and dormers. Count ridge cap, starter strip and underlayment separately.
Common mistakes to avoid
- Measuring the run along the roof surface instead of level.
- Using the full span instead of half the span for a gable rafter.
- Mixing units, such as a rise in inches over a run in feet.
- Using the common run for a hip or valley instead of the 45-degree diagonal.
Pitch also affects which roofing products and underlayment are allowed, so check local building codes and the manufacturer’s instructions, and use fall protection on any roof.
Where RoofPitch helps
RoofPitch: Rafter Calc
RoofPitch is an iPhone calculator for these steps. Enter rise and run in feet and inches or meters and centimeters, and it shows the x-in-12 pitch, the angle and the percent grade at once, with a live cross-section that steepens with the pitch. You can save each roof to a Jobs library on your device and reopen or edit it later.
Pitch and angle are free. A one-time Pro unlock, with no subscription, adds common rafter length with ridge shortening and the overhang tail, hip and valley lengths on the 45-degree plan diagonal with the hip angle, roof area, roofing squares and shingle bundles with your own waste allowance, plus a per-roof PDF cut sheet and a CSV of your library. RoofPitch is a calculator and estimating aid, so check local codes and material coverage before you cut or order.
Questions and answers
What is a 4/12 roof pitch in degrees?
A 4/12 pitch rises 4 inches for every 12 inches of run, which is about 18.4 degrees or a 33.3% grade.
How do I convert roof pitch to degrees?
Divide the rise by the run and take the arctangent. For a 6/12 pitch, 6 ÷ 12 = 0.5, and the arctangent of 0.5 is about 26.6 degrees.
How do I find rafter length from pitch?
Multiply the rafter’s level run, half the span on a gable, by the slope factor, the square root of 1 + (rise ÷ run)². A 12-foot run at 6/12 gives 12 × 1.118 = about 13.42 feet before ridge shortening and overhang.
How many bundles of shingles make a square?
Many common asphalt shingles are packed three bundles to a square, which covers 100 square feet. Some products differ, so check the coverage on the wrapper.
Is RoofPitch free?
Pitch and angle in RoofPitch are free. Rafter lengths, roof area, the material estimate and export come with a one-time Pro unlock, not a subscription.
This guide is general information. Check local building codes and product instructions, and use a qualified professional for structural work and work at height.