Roofing

Rafter Length Calculator

Calculate the length of a common rafter for a symmetric gable roof from the building span, roof pitch, overhang, and ridge board thickness, with an optional rafter count.

Last reviewed: November 11, 2026

Project measurements

Measurement system

This calculator measures a common rafter on a symmetric gable roof only. It does not size rafters or interpret building codes. See the disclaimer.

How to use this calculator

  1. Choose US customary or metric measurements.
  2. Enter the building span, which is the horizontal distance between the outside edges of the two supporting walls.
  3. Enter the roof pitch as rise per 12 units of run, plus the overhang and ridge board thickness if they apply.
  4. Add the building length and the rafter spacing if you also want a rafter count.

How the calculation works

A common rafter runs from the top of the wall up to the ridge. Its horizontal run is half the span, less half the thickness of the ridge board. The length along the slope is that run times the pitch multiplier, which is the square root of one plus the squared rise over run. The overhang is measured horizontally and converted the same way.

Formula

Run = span ÷ 2 − ridge board thickness ÷ 2
Pitch multiplier = √(1 + (rise ÷ 12)²)
Rafter length = (run + overhang) × pitch multiplier

Worked example

A 24 ft span with a 6/12 pitch has a 12 ft run and a pitch multiplier of 1.118, so the rafter measures 13.42 ft, or 13 ft 5 in, before any overhang. A 1 ft horizontal overhang makes it 14.53 ft, or 14 ft 6 3/8 in. The roof angle is 26.6°.

Common rafter length at 6:12

This table uses the formula's run and pitch multiplier of 1.118 at 6:12, with no overhang and ignoring the ridge board.

SpanRunRafter length
12 ft6 ft6.71 ft
16 ft8 ft8.94 ft
20 ft10 ft11.18 ft
24 ft12 ft13.42 ft
28 ft14 ft15.65 ft

A second example with an overhang and a ridge board

A 20 ft span at 8:12 has a 10 ft run and a multiplier of 1.202. With a 1.5 ft horizontal overhang, the rafter is 11.5 x 1.202 = 13.82 ft, or about 13 ft 9.8 in. A 1.5 in ridge board removes half its thickness (0.75 in) from the run, shortening the rafter by about 0.9 in.

What the length leaves out

The figure is measured along the top edge. The plumb cut at the ridge and the birdsmouth seat on the wall plate change where the board starts and ends, so add allowance for cuts when ordering stock. Rafter size, spacing, and spans come from local code tables and the structure, not from this tool.

Checking your work

  • The rafter must be longer than the run.
  • At 12:12 the rafter is 1.414 times the run.
  • Divide the length by the multiplier to get the run back.

Project considerations

  • The length is measured along the top edge of the rafter. It does not include birdsmouth, plumb, or tail cuts, which depend on the framing detail.
  • Rafter size, spacing, and allowable span come from local code and span tables, not from this tool.
  • Hip, valley, and jack rafters have different geometry. This tool covers a common rafter on a symmetric gable roof.
  • Rafters are cut from stock lengths and trimmed on site, so plan for a little extra length.

Frequently asked questions

What is the difference between rafter length and span?

Span is the horizontal distance between the walls. Rafter length is measured along the sloped roof, so it is always longer than half the span.

Do I include the overhang in the span?

No. Enter the span between the supporting walls, then enter the overhang separately. It is treated as extra horizontal run beyond the wall.

References

Published sources for context. They are not used in the calculation.