Rafter Length Calculator

Rafter Length Calculator | Estimate Roof Rafters, Pitch, Run & Cost
Rafter Length Calculator • Run, Rise, Pitch, Angle & Cost

Rafter Length Calculator

Estimate common rafter length, roof run, roof rise, pitch angle, overhang length, rafter count, lumber length, waste allowance, and material cost for gable roofs, shed roofs, porch roofs, garages, cabins, and roof framing projects.

Calculate Rafter Length

Outside wall-to-wall width in feet
Enter a valid span greater than 0.
Rise in inches per 12 inches of run
Horizontal overhang in inches
Enter a valid overhang of 0 or more.
Optional local lumber price
Advanced Options
Length along ridge/eave in feet

Your Rafter Estimate

Common Rafter Length0 ft
Rise0 ft
Pitch Angle
Estimated Cost$0

Formula used:

Practical recommendation:

Quick Formula Box

Gable roof run = (building span − ridge thickness) ÷ 2

Shed roof run = building span

Rise = run × pitch ÷ 12

Common rafter length = √(run² + rise²)

Overhang rafter length = overhang × √(1 + (pitch ÷ 12)²)

Total rafter length = common rafter length + sloped overhang length

Pitch angle = arctan(pitch ÷ 12)

This calculator estimates common rafter length for a simple roof plane. It does not calculate hip rafters, valley rafters, structural capacity, birdsmouth depth, ridge beam design, collar ties, rafter thrust, snow load, wind uplift, or code-required connections.

Rafter Pitch Reference Table

Roof PitchAngleLength Factor per 1 ft RunTypical UsePlanning Note
2/129.46°1.014 ftLow-slope roofs where allowedRoofing material limits are very important.
3/1214.04°1.031 ftLow to moderate slopeOften needs special underlayment rules.
4/1218.43°1.054 ftCommon residential roofsEasy to frame and walk compared with steeper roofs.
6/1226.57°1.118 ftVery common gable roof pitchGood balance of drainage and attic space.
8/1233.69°1.202 ftSteeper architectural roofsLonger rafters and more roof area.
10/1239.81°1.302 ftSteep roofsMore challenging cutting, bracing, and safety planning.
12/1245.00°1.414 ftVery steep roofsRafter length grows quickly as pitch increases.

How to Use the Rafter Length Calculator

Enter the building width or roof span. For a gable roof, this is the outside wall-to-wall width across the roof.
Choose the roof pitch. Pitch is written as rise over 12, such as 6/12, meaning the roof rises 6 inches for every 12 inches of horizontal run.
Enter the horizontal overhang in inches. The calculator converts it to sloped rafter length automatically.
Enter the price per rafter board if you want a quick material cost estimate.
Open Advanced Options only if you need to change units, roof length, spacing, stock board length, waste allowance, or ridge thickness.
Click Calculate to see rafter length, run, rise, pitch angle, rafter count, board count, lumber length, cost, formula, and recommendation.

Rafter Length Calculator Guide

A rafter length calculator helps estimate the sloped length of a roof rafter from the roof span, pitch, and overhang. Rafters are the sloping framing members that run from the wall plate to the ridge or upper support. They support roof sheathing, roofing material, underlayment, snow load, wind loads, and other roof loads. Accurate rafter length is important for ordering lumber, cutting rafters, laying out birdsmouth cuts, and planning roof framing.

This calculator focuses on the most common first-step calculation: common rafter length. A common rafter is used on a simple gable roof or shed roof plane. The calculator also estimates roof run, rise, pitch angle, overhang length along the slope, rafter count, stock boards, waste allowance, and cost. It is designed for preliminary material planning, not final structural design.

What This Rafter Length Calculator Does

This tool estimates common rafter length, total sloped length with overhang, roof run, rise, pitch angle, roof length factor, number of rafters, board count, total linear feet, waste allowance, and material cost. It is useful for homeowners, carpenters, shed builders, porch builders, roof framers, remodelers, contractors, cabin builders, and DIY users planning simple roof framing materials.

The default workflow uses only four main inputs: building span, roof pitch, overhang, and price per rafter board. A roof type selector adjusts whether the run is treated as half-span for a gable roof or full span for a shed/lean-to roof. Advanced options include units, roof length, rafter spacing, stock board length, waste allowance, and ridge thickness. This keeps the calculator fast while still supporting practical estimating.

Why Rafter Length Matters

Rafter length affects lumber ordering, roof geometry, roof area, cutting accuracy, fascia alignment, ridge layout, and waste. A small mistake in rafter length can lead to poor fit at the ridge, uneven eaves, incorrect overhang, or extra cutting. For a full roof, repeated small errors can turn into a large layout problem.

Rafter length also affects cost. Steeper roofs use longer rafters than low-pitch roofs for the same building width. Overhangs add additional sloped length. Stock board length matters because a 12-foot rafter may not be practical from a 10-foot board. Estimating rafter length before buying lumber helps reduce waste and avoid short boards.

Key takeaway: common rafter length is based on horizontal run and roof rise. The rise comes from pitch, and overhang must be converted from horizontal distance to sloped distance.

Rafter Length Formula Explained

The basic rafter length calculation uses the Pythagorean theorem. A roof rafter forms the hypotenuse of a right triangle. The horizontal run is one leg, and the roof rise is the other leg. The rafter length is the sloped side.

For a gable roof, the run is usually half the building span, adjusted for ridge board thickness when desired:

Run = building span ÷ 2

For a shed roof or lean-to roof, the run may be the full horizontal distance from the lower support to the upper support:

Run = roof span

Roof pitch tells you how much the roof rises for every 12 inches of run:

Rise = run × pitch ÷ 12

Then the rafter length is:

Rafter length = √(run² + rise²)

For example, a 24-foot-wide gable roof with a 6/12 pitch has a run of about 12 feet. The rise is 12 × 6 ÷ 12, or 6 feet. The common rafter length before overhang is √(12² + 6²), or about 13.42 feet.

Overhang and Sloped Length

Many roofs include an eave overhang. If the overhang is measured horizontally, it must be converted to the sloped length along the rafter. A 12-inch horizontal overhang on a 6/12 roof is not exactly 12 inches along the rafter; it is longer because it follows the slope.

The calculator uses a pitch factor:

Pitch factor = √(1 + (pitch ÷ 12)²)

Then it multiplies the horizontal overhang by the pitch factor. This creates a better estimate for the extra rafter length needed beyond the wall line. Final rafter cutting may still need adjustment for fascia, birdsmouth seat cut, plumb cut, ridge contact, and tail details.

Did you know? A 12/12 roof has a 45-degree angle, so every 1 foot of horizontal run needs about 1.414 feet of rafter length before overhang.

Practical Applications

Homeowner Uses

Estimate rafters for a shed, garage, porch, cabin, or simple gable roof.
Compare how 4/12, 6/12, 8/12, and 12/12 pitches change rafter length.
Estimate roof rise and pitch angle before planning framing cuts.
Plan rafter board length and cost before buying lumber.

Contractor Uses

Prepare quick rafter material estimates during early planning.
Explain roof pitch, run, rise, and overhang to clients.
Estimate rafter count from roof length and spacing.
Plan waste allowance for birdsmouth cuts, tails, blocking, and layout.

Common Mistakes to Avoid

A common mistake is using the full building width as the rafter run for a gable roof. For a standard gable roof, each common rafter usually runs from the wall to the ridge, so the run is half the span. Shed roofs are different because one rafter may run the full roof depth from low wall to high wall.

Another mistake is forgetting the overhang. If you calculate only wall-to-ridge length, your rafters may be too short for eaves. Users also sometimes measure pitch incorrectly. A 6/12 pitch means 6 inches of rise per 12 inches of horizontal run, not 6 degrees.

Ridge thickness can also affect layout. When rafters meet against a ridge board, the theoretical run may need adjustment by half the ridge thickness. This calculator includes an optional ridge thickness setting for estimating, but final cuts should be laid out from actual framing conditions.

Expert Recommendations

Use the calculator for estimating and planning, then verify final rafter cuts with a framing square, speed square, construction calculator, or framing plan. Mark one test rafter carefully before cutting the full batch. Confirm the birdsmouth seat cut, plumb cut, ridge cut, tail length, fascia detail, and wall plate position.

For structural design, verify rafter size, species, grade, spacing, span, roof load, snow load, wind uplift, ceiling joists, collar ties, ridge beam requirements, bracing, and fastening. Roof framing is structural work, so material quantity is only one part of a safe roof assembly.

Conclusion

This rafter length calculator gives a fast, practical estimate for common rafter length, roof run, rise, pitch angle, overhang length, rafter count, board count, waste allowance, and cost. It works for simple gable roofs, shed roofs, porch roofs, garages, cabins, and DIY roof framing projects. For best results, enter accurate span and pitch, include overhang, choose realistic rafter spacing, and verify final cuts and structural requirements before building.

Rafter Length Calculator FAQ

Find the roof run, calculate rise from pitch, then use the Pythagorean theorem: rafter length equals the square root of run squared plus rise squared. Add sloped overhang if needed.
Roof run is the horizontal distance from the outside wall to the ridge for a gable roof, or the horizontal span from low support to high support for a shed roof.
For a typical gable roof, yes. The common rafter run is usually half the building span, adjusted if needed for ridge board thickness.
A 6/12 pitch means the roof rises 6 inches for every 12 inches of horizontal run. It is about a 26.57-degree roof angle.
Before overhang, the run is about 12 feet and the rise is 6 feet, so the common rafter length is about 13.42 feet.
Yes. Horizontal overhang must be converted to sloped length using the pitch factor, then added to the common rafter length.
Yes. It estimates rafter pairs or single rafters from roof length and rafter spacing in the advanced options.
No. This tool focuses on common rafter length. Hip and valley rafters use different geometry and should be calculated separately.
It estimates rafter length, but it does not lay out birdsmouth depth or seat cuts. Birdsmouth layout should be done from the actual wall plate and framing details.
A 10% waste allowance is a practical default. Use more for complex roofs, steep pitches, birdsmouth mistakes, long tails, or selective lumber.
No. It estimates length and quantity only. Rafter size, spacing, span, species, grade, load, snow, wind, and code requirements must be verified separately.
No. It is a material and geometry estimator. Always verify final rafter design, connections, bracing, ridge support, and local building code before construction.