Skip to content
Saved
Menu

Rafter Length Calculator

Find the common rafter length, the overhang, and the birdsmouth from span and pitch.

Enter a span from 2 to 60 feet.

Roof type

2 to 60 feet, outside of one wall to outside of the other.

1 to 24. Editing this field sets the slope.

Derived from the pitch until you edit it.

Derived from the pitch and the run until you edit it.

The rafter length, overhang, and birdsmouth appear when the span is in range.

0 to 3 1/2 inches. A shed roof starts at 0.

0 to 48 inches, measured horizontally.

Wall plate

1 1/2 to 7 1/4 inches. Follows the wall plate until you edit it.

Spacing

Optional. Used only to count the rafters.

Saved projectsReport a problem

Code reference

  • Birdsmouth depth

    1/4 of the rafter depth

    IRC R802.7.1

    The notch perpendicular to the rafter edge.

  • Bearing length

    1 1/2 in minimum

    IRC R802.6

    The seat cut has to bear on the plate.

  • Seat on the plate

    No wider than the plate

    JLC

    A longer seat puts the load on the tip of the cut.

  • Overhang notch

    3 1/2 in of wood left

    IRC R802.7.1.1

    Shown as a note. This page does not cut the tail.

  • Asphalt shingles

    2/12 minimum

    IRC R905.2.2

    From 2/12 to 4/12, use a double underlayment.

Code checks reference the 2021 International Residential Code (section numbers for the 2024 edition shown in parentheses). States and cities adopt different editions and often amend them, so limits in your area may differ.

Based on the IRC model code. Your local jurisdiction may adopt a different edition or amendments — confirm with your building department.

How to measure

Building span is the horizontal distance from the outside face of one exterior wall to the outside face of the other. Set the tape at the framing, not at the outside of the siding, and keep it level. Record feet and inches. Pitch is the rise over a 12 inch run. Set a level 12 inches in from the wall, or along a known horizontal, and measure straight up to the underside of the roof or to the top of the rafter. That rise is the number before the slash. A 6 inch rise is 6/12. Overhang is the horizontal distance from the outside of the wall to the plumb cut at the tail. Measure it level, not along the sloping tail. Ridge thickness is the actual thickness of the ridge board, usually 1.5 inches for a 2x. On a shed roof leave it at zero when there is no ridge board. Wall plate width is the flat width of the top plate the seat will sit on, 3.5 inches for a 2x4 and 5.5 inches for a 2x6. Write the span, the pitch, and the overhang before you change the stock.

Formula

On a gable the run is half the span minus half the ridge thickness. On a shed the run is the span minus the ridge. The slope angle is the arctangent of the pitch divided by 12. The slope factor is the square root of 144 plus the pitch squared, divided by 12. Common rafter length is the run times that factor, and the overhang length is the horizontal overhang times the same factor. Total length adds those two. Rise is the run times the pitch divided by 12. The heel of the birdsmouth is the seat length times the pitch divided by 12, and the notch depth is the seat times the sine of the angle. The cut length adds the stock width times the tangent of the angle, plus 2 inches, to the total length.

A 24 foot span at 6/12 with a 1.5 inch ridge and a 12 inch overhang needs a 160.16 inch rafter, a 173.57 inch total, and a 16 foot board.

Common mistakes

  • Measuring the span inside the rooms instead of outside face to outside face.
  • Entering the sloping tail length as the horizontal overhang.
  • Leaving a 1.5 inch ridge on a shed roof that has no ridge board.
  • Setting a seat longer than the wall plate and ignoring the warning.
  • Buying the line length and forgetting the extra wood for the plumb cuts.

FAQ

How do I measure the span?

Measure from the outside face of one wall to the outside face of the other, and keep the tape level. Record feet and inches. Do not measure inside the rooms, and do not include siding that sits outside the framing. The pitch is the inches of rise for every 12 inches of horizontal run. The overhang is the level distance from that wall to the rafter tail.

What does a 6/12 pitch mean?

Pitch is how many inches the roof rises for each 12 inches of horizontal run. A 6/12 roof rises 6 inches over one foot of run. The page also shows that slope as an angle and as a total rise over the rafter run. Edit any one of the three and the other two follow. The angle and the total rise stay derived until you type in those fields.

How is the birdsmouth found?

The run is half the span minus half the ridge on a gable, or the whole span minus the ridge on a shed. Rafter length is that run times the slope factor. The overhang length uses the same factor on the horizontal overhang. The birdsmouth heel is the seat times the pitch divided by 12, and the notch depth is the seat times the sine of the angle.

Why does the seat follow the wall plate?

The seat cut usually matches the wall plate so the whole seat bears on the plate. A 2x4 plate is 3.5 inches and a 2x6 plate is 5.5 inches. Until you edit the seat, switching the plate updates the seat, and a custom plate wider than 7.25 inches stops the seat at 7.25. Match wall plate restores that link. A seat wider than the plate is a warning, because the load then sits on the tip of the cut.

What length do I buy?

The line length is the common rafter plus the overhang. The board must also cover the plumb cuts at the ridge and the tail, so the page adds the stock width times the tangent of the angle, plus 2 inches of allowance. Buy is the shortest stock length that covers that cut length. Stock lengths stop at 20 feet. A longer rafter shows no buy length, and you will need a special order or a splice.

Does a passing check mean the rafter meets my local code?

A passing row means the number meets the model-code limit printed beside it. Birdsmouth depth and bearing follow the 2021 IRC. The seat-to-plate comparison is a professional warning, not a code maximum. Your city may adopt another edition or amend a number. A pass is not a permit, and this page does not check whether the rafter span can carry the roof load. Confirm the adopted code before you order lumber.

Browse lumber calculators

By Lumber Calc Editorial Team · Verified against 2021/2024 IRC & AWC DCA 6 · Last updated Oct 24, 2026