Free calculator

Rafter Length Calculator from span, pitch and overhang

Enter the building span, the pitch, the overhang and the ridge board. You get the common rafter length in feet and inches, the tail, the rise and the stock length to buy.

The formula

Common rafters on a roof with one pitch, meeting at a ridge board. Lengths are along the rafter's measuring line.

Run
span ÷ 2 − ridge board ÷ 2 Half the span, shortened by half the ridge board's thickness.
Pitch factor
√(1 + (rise ÷ 12)²) Rounded to 3 decimals in the table; the calculator uses the full value.
Rafter, ridge to wall line
run × pitch factor
Tail
overhang × pitch factor The overhang is measured level, from the wall.
Rafter length with tail
rafter + tail Buy the next stock length up.
Rise
span ÷ 2 × rise ÷ 12 From the top of the wall plate to the ridge's centre line.

Worked example

A house 28 ft wide with a 6/12 roof, a 12 in overhang and a 1½ in ridge board.

  1. Pitch factor at 6/12: √(1 + 0.5²) = 1.118
  2. Run: 28 ÷ 2 = 14 ft, minus half the ridge board (¾ in = 0.0625 ft) = 13.9375 ft
  3. Rafter, ridge to wall line: 13.9375 × 1.118 = 15.58 ft (15 ft 7 in)
  4. Tail: 12 in × 1.118 = 13.4 in (1 ft 1⅜ in)
  5. Rafter length with tail: 15.58 + 1.12 = 16.70 ft (16 ft 8⅜ in)
  6. Rise, plate to ridge: 14 × 6 ÷ 12 = 7 ft
  7. Stock length: the next length above 16.70 ft is 18 ft

Each common rafter is 16 ft 8⅜ in with its tail: buy 18 ft stock.

Rafter length per 10 ft of run by pitch

Common rafters, before the ridge deduction and the tail. Multiply by your run ÷ 10.
PitchPitch factorRafter per 10 ft of runRise per 10 ft of run
3/121.03110.31 ft2.50 ft
4/121.05410.54 ft3.33 ft
5/121.08310.83 ft4.17 ft
6/121.11811.18 ft5.00 ft
7/121.15811.58 ft5.83 ft
8/121.20212.02 ft6.67 ft
9/121.25012.50 ft7.50 ft
10/121.30213.02 ft8.33 ft
11/121.35713.57 ft9.17 ft
12/121.41414.14 ft10.00 ft

Span, run and the ridge deduction

The span is the building's width, outside of wall to outside of wall. The run is half of it: the level distance one rafter covers. On a 28 ft wide house, that's 14 ft.

When the rafters land against a ridge board, each one stops half the board's thickness short of the centre. Take that off the run before you multiply: ¾ in for a 1½ in board. Skip it and every rafter comes out long.

Adding the overhang

The overhang is measured level, from the outside of the wall to the end of the tail. Like the run, it gets longer along the slope: multiply it by the same pitch factor. A 12 in overhang at 6/12 adds 13.4 in of rafter.

If you'll cut the tails square or plumb after the rafters are up, add a few inches to trim. The calculator gives the line length, not a cutting allowance.

Buying the lumber

Rafters are bought in 2 ft steps, so round the length with the tail up to the next stock length: 16 ft 8⅜ in calls for 18 ft. If the length lands within an inch or two of a stock length, check your layout before you count on the shorter board.

The lumber size and the spacing are a different question. They come from your local code's span tables or the engineer, not from this calculator.

Where the formula stops

The formula is for common rafters on a roof with one pitch. Hip and valley rafters run on the diagonal and need the hip and valley factor; jack rafters get shorter step by step.

Roofs with two pitches, or rafters that sit on a beam instead of a ridge board, need their own layout. For a re-roof, you don't need rafter lengths at all: RoofStruct gives you free, unlimited self-serve measuring and PDF reports, no card, with every plane's pitch and area.

Rafter questions

How do you calculate rafter length?
Take half the span, subtract half the ridge board, and multiply by the pitch factor √(1 + (rise ÷ 12)²). Add the overhang times the same factor for the tail.
What is the ridge board deduction?
Half the ridge board's thickness, taken off the run, because each rafter stops at the face of the board. For a 1½ in board, it's ¾ in.
Does rafter length include the overhang?
Not on its own. Work out the tail as the overhang times the pitch factor and add it. The calculator shows both.
How long is a rafter on a 28 ft span at 6/12?
About 15 ft 7 in from the ridge board to the wall line. With a 12 in overhang it's 16 ft 8⅜ in, so you buy 18 ft stock.
Can I use this for hip or valley rafters?
No. Hips and valleys run on the diagonal, so they need the hip and valley factor. Use the hip and valley calculator.