Skip to main content

Free Tool

Get the rafter length before you cut

Enter the span, pitch, overhang and ridge thickness. You get the common rafter length in feet and inches, plus rise, run, hip and valley lengths, the plumb-cut angle and how many rafters the job takes.

ft

Outside to outside of the wall plates. Run is half of this.

Rise in inches per 12 inches of run.

in

Measured horizontally from the wall, not along the rafter.

in

1.5" for a 2x ridge board. Half of it comes off each rafter.

ft

Used only for the rafter count.

Common rafter, ridge to tail

14' 10 1/16"

per rafter

13' 5"

line length (ridge to wall)

6' 0"

total rise

12' 0"

run (half the span)

18' 0"

hip / valley rafter

26.6°

plumb cut angle

62

rafters at 16" o.c.

Slope factor 1.1180 — every horizontal inch is 1.1180" along the rafter. Ridge deduction 0 13/16", overhang 1' 5 7/8" along the slope. Order stock one size up and cut to the line.

Get the next tool first

New free calculators and one short weekly tip for running a trades business — no spam, unsubscribe anytime.

How this is calculated

Run is half the span. Rise is run × pitch ÷ 12. Line length is √(run² + rise²), which is the same as run × the slope factor, √(144 + pitch²) ÷ 12.

The cut length is the line length minus half the ridge thickness plus the overhang — with both of those multiplied by the slope factor first, because they are specified horizontally. The plumb-cut angle is arctan(pitch ÷ 12) from vertical.

Hip and valley rafters take the diagonal run, so their length is √(2 × run² + rise²) — the familiar “17 instead of 12” rule, since 17 approximates the 16.97 diagonal of a 12 × 12 square.

Lengths and counts only. Rafter sizing— depth, species, grade and spacing for a given load — comes from the span tables in your code book, and anything structural is the engineer's call.

This is a planning estimate — always confirm against code, spec, and your supplier before ordering or installing.

Rafter Calculator: FAQ

How do you calculate rafter length?

Rafter length is the hypotenuse of the run and the rise. Take half the span as the run, multiply the run by the pitch over 12 to get the rise, then take the square root of run squared plus rise squared. A 24 ft span at 6/12 gives a 12 ft run, a 6 ft rise and a line length of about 13 ft 5 inches. Subtract half the ridge thickness and add the overhang to get the length you actually cut.

Is the run the same as the span?

No, and mixing them up doubles the answer. The span is the full width of the building, wall plate to wall plate. The run is the horizontal distance one rafter covers, which on a symmetrical gable roof is half the span. This calculator takes the span and halves it for you.

How much do you deduct for the ridge board?

Half the ridge thickness, because each rafter meets it from one side — 3/4 inch for a standard 1.5 inch 2x ridge. It is a horizontal measurement, so multiply it by the slope factor before taking it off the rafter rather than deducting 3/4 inch straight.

Does the overhang get added along the rafter or horizontally?

Overhang is normally specified horizontally, from the outside of the wall, so it has to be multiplied by the slope factor to become length along the rafter. At 6/12 a 16 inch horizontal overhang is about 17.9 inches along the rafter. Cutting 16 inches leaves the eave short — this is the most common source of error.

What is the slope factor?

The length along the rafter for every one unit of horizontal run — the square root of 144 plus the pitch squared, all over 12. At 6/12 it is 1.1180, so every horizontal foot is 1.118 feet of rafter. It is the multiplier behind rafter length, overhangs, ridge deductions and sloped roof area.

How is a hip or valley rafter different?

A hip or valley rafter runs diagonally across the corner, so its horizontal run is the common run times the square root of two while the rise stays the same. That is where the framing rule of thumb of using 17 instead of 12 comes from — 17 is close to the 16.97 diagonal of a 12 by 12 square.

How many rafters do I need?

Divide the building length by the spacing and add one for the closing rafter, then double it for both slopes of a gable. A 40 ft building at 16 inch centres needs 31 per side, so 62 in total. Add rafters for any openings, and check the span tables — this tool gives lengths and counts, not structural sizing.

More free tools

All tools