Skip to content
Get matched

Home › Rafter calculator

Calculator · 2026

Rafter calculator

How long does a rafter need to be?

Rafter length = run x pitch factor, plus the overhang. For a 24 ft span at a 6/12 pitch with a 12-inch overhang, a common rafter is about 14 ft 5.625 in: order 16 ft lumber.

How the calculator works

  1. Run = half the span, minus half the ridge board thickness.
  2. Pitch factor = √(1 + (rise/12)²). A 6/12 pitch is 1.118.
  3. Rafter to the wall line = run x pitch factor; tail = overhang x pitch factor.
  4. Count = rafters at the chosen spacing along the building, both ends included, for both sides of the ridge.

The length is measured along the top edge from the ridge plumb cut to the tail; the birdsmouth seat cut does not change it. Order the next standard lumber length up.

Sizing is not included. Rafter size and grade must come from the span tables in your local code (IRC Table R802.4.1) or an engineer, based on snow, dead load and spacing. Trusses instead? See the roof truss calculator. Pitch help: roof pitch calculator.

Sources for the figures on this page

Rafter spacing (IRC span tables)

Lengths are geometry. This tool is for planning and material ordering, not structural design. Written by the Thomas Town Digital editorial team.

Rafter questions

How do you calculate rafter length?

Run x pitch factor. The run is half the building span minus half the ridge board thickness; the pitch factor is the square root of 1 + (rise/12)². Add the overhang, also multiplied by the pitch factor, for the tail.

How long is a rafter for a 24-foot span at 6/12?

With a 1.5-inch ridge board and a 12-inch overhang, about 14 ft 5.625 in along the slope (13 ft 4.125 in to the wall line plus 1 ft 1.375 in of tail), so order 16-foot lumber.

What angle is the plumb cut?

The plumb cut angle equals the roof angle: 26.57° for a 6/12 pitch, 33.69° for 8/12 and 45° for 12/12.

How far apart are rafters spaced?

The IRC rafter span tables list spacings of 12, 16, 19.2 and 24 inches on center. 16 and 24 inches are common; the allowed span depends on lumber size, grade and loads.