Rafter Length Calculator for a Gable Roof
Rafter length is the hypotenuse of the run and rise triangle. Enter your span and pitch to get the line length, plus the overhang and ridge deduction.
Rafter Length Calculator for a Gable Roof
Rafter length is the hypotenuse of the run and rise triangle. Enter your span and pitch to get the line length, plus the overhang and ridge deduction.
| 4/12 pitch multiplier | 1.054 |
|---|---|
| 6/12 pitch multiplier | 1.118 |
| 8/12 pitch multiplier | 1.202 |
| 12/12 pitch multiplier | 1.414 |
Roof Pitch Calculator — instant results
Show calculation steps
- Multiplier = √(6² + 12²) ÷ 12 = √180 ÷ 12 = 1.118
- Angle = atan(6/12) = 26.57°
The manual math behind the answer
A common rafter on a gable roof is the long side of a right triangle. The run is half the building span, measured horizontally from the outside of the wall to the centre of the ridge. The rise is how far the roof climbs over that run, set by the pitch: a 6/12 pitch rises 6 in for every 12 in of run.
For a 24 ft span the run is 12 ft. At 6/12 the rise is 12 ft × 6/12 = 6 ft. Rafter line length = √(run² + rise²) = √(144 + 36) = √180 = 13.42 ft, or 13 ft 5 in.
The shortcut most framers use is a pitch multiplier — the ratio of rafter length to run for a given pitch. Multiply the run by 1.031 for 3/12, 1.054 for 4/12, 1.083 for 5/12, 1.118 for 6/12, 1.202 for 8/12, 1.302 for 10/12 and 1.414 for 12/12. The same 12 ft run at 6/12 gives 12 × 1.118 = 13.42 ft, matching the long-hand answer.
Two corrections turn line length into cut length. Add the overhang, measured along the slope: a 16 in horizontal overhang at 6/12 becomes 16 × 1.118 = 17.9 in of extra rafter. Then subtract half the ridge board thickness measured square to the plumb cut — 3/4 in for a 1.5 in ridge — because the line length runs to the theoretical centre of the ridge.
Count the rafters with the grid formula: (roof length ÷ spacing) + 1, doubled for both sides of the gable. A 40 ft long roof at 16 in on centre needs (480 ÷ 16) + 1 = 31 rafters per side, 62 total, plus gable-end studs and any structural ridge. Order the next stock length above 13 ft 5 in — a 14 ft board — and check the span tables for your lumber size, species and snow load before cutting.
Quick reference
| 4/12 pitch multiplier | 1.054 |
|---|---|
| 6/12 pitch multiplier | 1.118 |
| 8/12 pitch multiplier | 1.202 |
| 12/12 pitch multiplier | 1.414 |
Frequently asked questions
How do you calculate rafter length from pitch?
Multiply the horizontal run by the pitch multiplier — 1.118 for a 6/12 roof — then add the sloped overhang and subtract half the ridge thickness.
What is the run on a gable roof?
Half the total building span, measured horizontally from the outside of the wall plate to the centreline of the ridge.
How far apart should rafters be?
16 or 24 inches on centre, depending on rafter size, span, roofing weight and snow load. Confirm against the span table for your species and grade.
Planning estimate only, produced from the formulas shown above with the stated assumptions. Confirm quantities with your supplier and follow local code before ordering or building.