HomeMatchup
Free roofing tool

Rafter length calculator

Find the common rafter length from your run and roof pitch.

Enter your horizontal run and roof pitch to get the common rafter length. Handy for framing a roof, addition, shed, or porch.

Your numbers

Common rafter length
-

Add overhang length and account for ridge board thickness when cutting.

Get a real quote from a vetted pro
The math

How this calculator works

No black box - this is the arithmetic the tool runs, written out.

rafter length = run × √(1 + (rise ÷ 12)²)
run
Horizontal distance in feet from the outside wall to the ridge - usually half the building width for a simple gable.
rise
The pitch rise in inches per 12 inches of run.

The rafter is the hypotenuse of a right triangle whose base is the run and whose height is set by the pitch. The square-root term is the same slope multiplier the pitch calculator reports.

This gives the common rafter - the ones running straight from wall to ridge. Hip and valley rafters run diagonally and are longer; they need a different multiplier.

Worked example

What it looks like with real numbers

Starting from

Run
14 ft
Pitch
6/12

The working

  1. Slope multiplier: √(1 + (6 ÷ 12)²) = 1.118
  2. Length: 14 × 1.118 = 15.65

15.65 ft - common rafter line length

Reading it: That is the theoretical line length from the outside wall to the ridge. Your actual cut is longer by the overhang you want, and shorter by half the ridge board thickness.

Step by step

How the calculation runs

Four operations, in this order. Nothing is hidden behind a button.

  1. Take the horizontal run from wall to ridge.
  2. Derive the slope multiplier from the pitch.
  3. Multiply run by that multiplier to get the common rafter line length.
Reference

Roof pitch multipliers

A sloped roof has more surface than the ground it covers. This is the multiplier for every common pitch, applied to a 2,000 sq ft footprint - and it is the step most DIY estimates skip.

PitchFactorRoof areaExtra vs footprintAccess
3/12 (low slope)1.0312,062 sq ft+3%Usually walkable
4/121.0542,108 sq ft+5%Usually walkable
5/121.0832,166 sq ft+8%Usually walkable
6/12 (common)1.1182,236 sq ft+12%Usually walkable
7/121.1582,316 sq ft+16%Staging likely
8/12 (steep)1.2022,404 sq ft+20%Staging likely
9/121.252,500 sq ft+25%Staging likely
10/12 (steep)1.3022,604 sq ft+30%Staging likely
12/12 (very steep)1.4142,828 sq ft+41%Staging likely

Steeper costs more twice over: there is literally more roof, and the crew works slower on it. That is why a 12/12 roof is not 41% more expensive than a flat footprint - it is more.

Before you start

Getting your inputs right

The answer is only as good as what goes in. This is where estimates usually go wrong.

  1. Run is half the span, for a simple gable

    Measure the building width outside-to-outside and halve it. That is the horizontal distance one common rafter covers.

  2. Get the pitch from the plan or the existing roof

    On new framing it is a design decision. On a repair, match what is there using the pitch calculator.

  3. Decide your overhang before cutting

    The calculator gives the line length. Add your intended overhang to get the piece you actually cut.

Variables

What changes your number

A calculator applies an average. These are the things that decide where in the range you actually land.

  • Pitch Steeper pitch, longer rafter for the same run. The multiplier is the same slope factor used everywhere else on the site.
  • Ridge board thickness The rafter meets the ridge board, so the line length is reduced by half its thickness at the top cut.
  • Common versus hip and valley This is the common rafter. Hip and valley rafters run diagonally and are longer - a different calculation.
Get it right

Common mistakes

Every one of these is something people genuinely do, and most of them cost real money.

  • Cutting all the rafters before testing one Cut one, offer it up, check the birdsmouth and the ridge cut, then cut the rest. This is the oldest advice in framing and it is still the right advice.
  • Forgetting the birdsmouth The notch that seats the rafter on the wall plate is not in this length. It is a cut, not an addition, but it has to be laid out from the line length correctly.
  • Using this for hip rafters Hips run diagonally across the plan and are longer than commons at the same pitch. This formula does not apply to them.

How rafter length is figured

The common rafter is the hypotenuse of the run and rise. Length = run × √(1 + (rise/12)²). This gives the line length from wall plate to ridge, before you add the overhang (tail) and subtract half the ridge thickness.

Cost ranges reflect 2026 U.S. installed prices (BLS producer/labor data, Remodeling Cost vs. Value, and manufacturer pricing). Your real price depends on your roof, region, and pro - see the full cost guide.

Honest limits

Where this stops being accurate

This is the theoretical line length. It excludes your overhang, and it does not subtract half the ridge board thickness or account for the birdsmouth cut. Add your overhang and cut one rafter as a test pattern before you cut thirty.

This is a free estimating tool, not a quote. When you want a number somebody will stand behind, get matched with vetted local pros - they measure the roof before they price it.

Plain language

The terms on your quote, explained

A roofing quote is written in trade vocabulary. These are the words that actually change what you are paying for.

Square
100 square feet of roof surface. The unit the entire trade orders, prices, and quotes in - a 2,400 sq ft roof is 24 squares.
Pitch
The slope, written as rise over a 12-inch run. A roof climbing 6 inches per 12 horizontal inches is "6/12".
Decking (sheathing)
The structural panels over the rafters that everything else fastens to. Its condition is unknown until the old covering is off.
Underlayment
The water-resistant layer between decking and covering. Synthetic or felt; it is the roof's second line of defense.
Ice-and-water shield
A self-adhering membrane at eaves and valleys that seals around fasteners. Commonly required by code in freeze-thaw climates.
Flashing
Metal that seals the joins - around chimneys, walls, valleys and vents. Most roof leaks are flashing failures, not covering failures.
FAQ

Rafter Length Calculator questions

Want a real number? Get matched with a vetted local pro →

Multiply your run by the square root of (1 + (rise/12) squared). For a 12 ft run at 6/12 pitch, that’s about 13.4 ft, before overhang.
The run is the horizontal distance the rafter covers - usually half the building’s width, from the outside wall to the center ridge.
Yes. This tool gives the wall-to-ridge line length. Add your desired overhang (tail) and account for the ridge board thickness when marking cuts.
No - this is for common rafters. Hip and valley rafters run diagonally and use a longer factor. A framer or framing calculator handles those.
No. It is the line length from the wall to the ridge. Add whatever overhang you are building to get the piece you cut.
They need a different multiplier because they run diagonally in plan. This calculator handles common rafters only.
Effectively yes - the rafter follows the roof plane, so its line length is the sloped distance from wall to ridge.

The job will still be there next month.

It will just cost more, and you will be choosing in a hurry - which is how most people end up with the contractor they regret. Getting matched takes about a minute and costs nothing.

Free • No obligation • Licence & insurance verified

Who wrote and checked this

Written by

The HomeMatchup Content Team

Editorial
Michael Thompson, Senior Home Improvement Reviewer at HomeMatchup
Reviewed by

Michael Thompson

Senior Home Improvement Reviewer · 20 years

Twenty years on and around home improvement work. Reads our guides for the things that are technically true and practically wrong.

Every guide on this site is written by a member of our team and checked by someone else before it publishes, and every figure carries the source and the date we pulled it. Found a number that looks off? Tell us - corrections are the cheapest quality control we have.

(866) 582-8523 Get free quotes