How to Calculate Rafter Length from Rise and Run

By Zaid Hussain

Knowing how to calculate rafter length starts with a right triangle. The horizontal run forms the bottom, the vertical rise forms the upright side, and the rafter follows the diagonal.

The basic formula is:

Rafter line length = √(run² + rise²)

For example, a 12-foot run and a 6-foot rise produce a sloped line length of approximately 13.42 feet, before adding an overhang or adjusting for framing details.

This calculation gives you the geometry of a common rafter. It does not automatically provide a finished cutting dimension or tell you which timber size to use.

Below, you will learn how to work from rise and run, calculate from roof pitch, add an overhang and understand a ridge-board deduction.

How to Calculate Rafter Length: Understand the Measurements

Before using a formula, identify exactly where your measurements start and finish.

TermMeaning
RunHorizontal distance between the chosen lower and upper reference points
RiseVertical difference between those same reference points
Building spanFull horizontal width across the roof in this example
Rafter line lengthSloped distance connecting the reference points
Horizontal overhangDistance the rafter tail projects beyond the wall reference
PitchRoof rise per unit of horizontal run, commonly expressed as rise per 12

For a symmetrical gable roof with a centered ridge, the run to the ridge centerline is half the building span.

Run = building span ÷ 2

A 24-foot-wide building therefore has a 12-foot run on each side under those assumptions.

Do not automatically halve the span for an offset ridge or a single-slope shed roof. Use the actual horizontal distance for the rafter you are calculating.

Keep Your Reference Points Consistent

The run and rise must describe the same triangle.

For example, do not combine a run measured to the ridge centerline with a rise measured to a different point on the ridge board. That mismatch can change the result.

Write down whether your calculation ends at the ridge centerline or its face. This also helps prevent applying a ridge deduction twice.

Method 1: Calculate from Known Rise and Run

Use the Pythagorean theorem when you know both dimensions:

L = √(R² + H²)

Where:

  • L = sloped rafter line length
  • R = horizontal run
  • H = vertical rise

Keep both measurements in the same unit.

How to Calculate Rafter Length with a 12-Foot Run

Assume:

  • Horizontal run: 12 feet
  • Vertical rise: 6 feet
  • Overhang: excluded
  • Upper reference: ridge centerline

Square the run and rise:

12² = 144
6² = 36

Add them:

144 + 36 = 180

Take the square root:

√180 ≈ 13.4164 feet

The main rafter line is therefore approximately 13.42 feet.

How to Calculate Rafter Length in Feet and Inches

Convert the decimal part of the result into inches:

0.4164 × 12 ≈ 5.00 inches

So 13.4164 feet is approximately 13 feet 5 inches.

Remember that 13.42 feet does not mean 13 feet 42 inches. Likewise, 12 feet 6 inches should be entered as 12.5 feet, not 12.6 feet.

Keep full precision during the calculation and round the final displayed result.

Method 2: Calculate from Roof Pitch and Run

If you know the roof pitch instead of the total rise, first convert pitch into a slope ratio.

A 6/12 pitch means the roof rises 6 units for every 12 horizontal units.

Rise = run × (pitch ÷ 12)

For a 12-foot run:

12 × (6 ÷ 12) = 6 feet of rise

You can then use the rise-and-run formula.

Alternatively, calculate the sloped length directly:

Rafter line length = run × √[1 + (pitch ÷ 12)²]

For a 6/12 pitch, the multiplier is approximately 1.118034.

12 × 1.118034 ≈ 13.4164 feet

For a fuller explanation of pitch ratios, angles and percentages, read our roof pitch explained guide.

Common Pitch Multipliers

The following examples use a 12-foot horizontal run. They exclude overhangs and ridge deductions.

Roof pitchMultiplierMain rafter line length
3/121.03077612.37 ft
4/121.05409312.65 ft
5/121.08333313.00 ft
6/121.11803413.42 ft
8/121.20185014.42 ft
12/121.41421416.97 ft

The steeper the roof, the longer the rafter line for the same horizontal run.

How to Calculate Rafter Length with an Overhang

An overhang extends the rafter beyond the wall. If the tail continues at the same pitch, convert its horizontal projection into a sloped length.

Sloped tail length = horizontal overhang × pitch multiplier

Using the previous 6/12 example with a 1-foot horizontal overhang:

1 × 1.118034 ≈ 1.1180 feet

Then add the tail to the main line:

13.4164 + 1.1180 ≈ 14.5344 feet

The total geometric line is approximately 14 feet 6.41 inches, before any ridge deduction or cutting adjustments.

ComponentCalculated length
Main line: 12 ft run at 6/1213.4164 ft
Tail: 1 ft horizontal overhang1.1180 ft
Total geometric line14.5344 ft

Do not simply add 1 foot to the sloped rafter length when the specified overhang is 1 foot horizontally.

However, if you already measured the tail along its slope, do not apply the multiplier again.

How Does Ridge-Board Thickness Affect the Result?

A calculation to the ridge centerline extends farther than a rafter that ends at the face of a centered ridge board.

For that specific arrangement, the horizontal adjustment is half the ridge board’s actual thickness. Convert that horizontal adjustment into a sloped deduction using the same pitch multiplier.

Sloped ridge deduction = (ridge thickness ÷ 2) × pitch multiplier

Suppose the ridge board is 1.5 inches thick and the pitch is 6/12:

Horizontal adjustment = 1.5 ÷ 2 = 0.75 inches

Sloped deduction = 0.75 × 1.118034 ≈ 0.839 inches

That deduction applies to a line originally calculated to the centerline. If your run already stops at the ridge face, do not subtract it again.

Framing contractor Don Dunkley explains this slope-adjusted shortening allowance in JLC’s Roof Calculations Simplified guide. jlconline.com

The appropriate adjustment depends on the actual ridge connection and reference points. It is not a universal deduction for every roof design.

A Metric Rafter Length Example

The same formulas work in metres.

Assume:

  • Main horizontal run: 4 metres
  • Roof pitch: 6/12
  • Horizontal overhang: 0.45 metres
  • Ridge adjustment: not included

First calculate the main line:

4 × 1.118034 ≈ 4.4721 metres

Then calculate the sloped tail:

0.45 × 1.118034 ≈ 0.5031 metres

Add them:

4.4721 + 0.5031 ≈ 4.9753 metres

The total geometric line is approximately 4.975 metres.

Pitch is a ratio, so a 6/12 slope works with metric measurements too. Do not mix millimetres and metres within the same calculation without converting them first.

Why Calculated Length Is Not a Finished Cut List

Understanding how to calculate rafter length solves the triangle. Preparing a rafter for installation also requires the project’s framing details.

These may include:

  • Ridge connection and actual ridge thickness.
  • Bearing location and birdsmouth layout.
  • Rafter depth and the chosen measuring line.
  • Tail cut and fascia position.
  • Extra stock needed to lay out and complete the cuts.

A birdsmouth is a notch that allows the rafter to bear on its support. Do not treat its depth as a simple amount to subtract from the diagonal length.

Similarly, length alone does not establish timber size, spacing or allowable span. Those depend on structural requirements, loads and the specified material.

Use the RooferTX Rafter Length Calculator

The Rafter Length Calculator accepts a horizontal run—or a symmetrical span—plus roof pitch and an optional horizontal overhang.

For the example in this article, enter:

Calculator inputValue
Measurement unitFeet
Starting measurementHorizontal run
Run12
Pitch: rise per 126
Horizontal overhang1

The total should be approximately 14.53 feet.

The tool reports geometric line lengths. It does not automatically calculate ridge-board deductions, birdsmouth cuts or structural suitability. RooferTX

If your next task is estimating roof covering, use the Roof Area Calculator. Rafter length is a linear measurement; roof area measures the surface to be covered.

Common Mistakes to Avoid

Using the full building width as the run.
For a symmetrical gable roof, each side’s centerline run is half the span.

Including the overhang twice.
Keep it separate if the calculator provides a dedicated overhang input.

Mixing horizontal and sloped measurements.
A pitch multiplier converts a horizontal distance into a sloped one. It should not be applied to a length already measured along the slope.

Subtracting half the ridge thickness directly from the diagonal.
In the centered-ridge example, half the thickness is a horizontal adjustment that needs slope conversion.

Using common-rafter inputs for a hip or valley rafter.
Those rafters follow different paths in plan. Their geometry needs a separate calculation.

Frequently Asked Questions

What Is the Formula for Rafter Length?

For a common-rafter line with a known horizontal run and vertical rise, use √(run² + rise²). Both measurements must refer to the same endpoints and use the same unit.

Can You Calculate Rafter Length Without Knowing the Rise?

Yes. If you know the run and pitch, calculate rise as run × pitch ÷ 12, or multiply the run by the pitch multiplier.

Does Rafter Length Include the Overhang?

Only if you include it in the calculation. A wall-to-ridge line excludes the tail beyond the wall. Add the sloped overhang separately when required.

Is Rafter Run Always Half the Building Span?

No. That applies to a symmetrical roof with a centered ridge reference. Offset ridges and shed roofs require the actual run.

Can This Formula Calculate a Hip Rafter?

The Pythagorean theorem still applies, but a hip rafter has a different horizontal path. Do not reuse a common rafter’s run without accounting for the roof’s plan geometry.

How Do You Choose the Timber Length to Buy?

Start with the calculated geometry, then establish the finished layout and required cutting allowance. Select available stock that accommodates those details; do not round down from the required length.

Before using any result, confirm the run, pitch, overhang and ridge reference. Then use the RooferTX Rafter Length Calculator to check the geometric calculation against your measurements.

Join the conversation

Your email address will not be published. Required fields are marked *

Scroll to Top