Skip to content
Woodshop Math

Structures and framing geometry · Guide 07

How to Calculate Rafters

Understand right-triangle rafter geometry and horizontal-versus-sloped distances.

By AUSV Systems

Publisher of Woodshop Math · How we source this

Published Reviewed 5 min read

This simplified common-rafter model turns a horizontal run and roof pitch into a sloped base length, then converts a horizontal overhang projection into a separate sloped extension. Reading each distance in the correct direction is central to interpreting the result.

Read the Roof Triangle

Horizontal run is the level distance from the outside wall line to the ridge line in the calculator's simple symmetrical-roof model. The calculator accepts the full span and uses half of it as this run; run and span are therefore not interchangeable inputs.

Roof pitch describes the slope. A ratio such as 5-in-12 means 5 units of vertical rise for every 12 units of horizontal run. Its equivalent angle is arctan(5 / 12), not 5 degrees.

The base sloped rafter length is the hypotenuse from the wall line to the ridge line before any overhang extension.

  • Span: the full width entered for the simple symmetrical roof model.
  • Horizontal run: half that span, from the wall line to the ridge line.
  • Roof angle or pitch: two ways to describe the triangle's slope.
  • Base sloped rafter length: the diagonal above the horizontal run before overhang.
  • Horizontal overhang projection: the level distance beyond the outside wall line.
  • Sloped overhang extension: the corresponding distance along the rafter slope.
  • Total sloped rafter length: base length plus the sloped extension.

Keep Horizontal and Sloped Distances Separate

Horizontal overhang (projection) is measured level from the outside wall line to the end of the overhang. It is not a measurement taken along the rafter.

If you measured along the sloping rafter, do not enter that value directly. At a non-zero roof angle, the sloped path over a horizontal projection is longer. The calculator divides the horizontal projection by the cosine of the roof angle to obtain the sloped overhang extension, then adds that extension to the base sloped length.

Overhang is entered level — the slope makes it longerwall lineridgehorizontal run = half the spanrise450 mm level487 mmalong sloperafterSloped extension = horizontal projection ÷ cos(roof angle)
The overhang is entered as a level projection of 450 mm. Measured along the slope that same overhang covers about 487 mm, which is an output of the calculation rather than an input to it.

The Geometry Used by the Calculator

Keep full precision through the trigonometry and round only displayed planning results. Early rounding of the converted angle or cosine can compound through both sloped lengths.

Formula

Roof angle = arctan(pitch rise / pitch run)

Base rafter length = horizontal run / cos(roof angle)

Sloped overhang extension = horizontal overhang projection / cos(roof angle)

Total rafter length = base rafter length + sloped overhang extension

Illustrative Example: Projection Versus Slope

Consider a simple symmetrical roof with a 7.4 m span, a 5-in-12 pitch, and a 450 mm horizontal overhang projection. These values illustrate input interpretation rather than a complete roof design.

The horizontal run is 7.4 / 2 = 3.7 m. A 5-in-12 pitch has angle arctan(5 / 12) = 22.6199° and produces 3.7 × 5 / 12 = 1.5417 m of rise.

Base sloped rafter length = 3.7 / cos(22.6199°) = 4.0083 m.

The overhang input is 450 mm = 0.45 m measured horizontally. Its sloped extension is 0.45 / cos(22.6199°) = 0.4875 m, which is longer than the horizontal projection.

Total sloped rafter length = 4.0083 + 0.4875 = 4.4958 m before separate cut, ridge, support, and trimming details. The 0.4875 m sloped distance is an output, not the overhang value to enter.

A Simple Interpretation Workflow

Use the calculator to keep the input directions explicit, then carry the geometric result into separate layout and design checks.

  1. Enter the full span used by the simple symmetrical-roof model.
  2. Describe the roof slope with the intended pitch mode: rise per 12, degrees, or rise and run.
  3. Enter any overhang once as a horizontal projection beyond the outside wall line.
  4. Review the base sloped length and converted sloped overhang as separate results.
  5. Add them for the model's total sloped geometric length.
  6. Verify the actual roof layout and non-geometric requirements separately.

Geometry Is Not Member Design

The simplified length does not automatically include ridge adjustments, birdsmouth or plumb-and-seat cuts, fascia details, or trimming.

It also does not select a structural member size or verify loads, spans, connections, roof-covering requirements, or code compliance. Those questions require project-specific information beyond this right-triangle calculation.

Use the Calculator for the Arithmetic

Use the Rafter Calculator to convert the selected pitch mode, horizontal span, and horizontal overhang projection into base, extension, and total sloped lengths. Its result remains geometry rather than a structural specification.

Common Mistakes

Most interpretation errors come from changing what a distance or slope input represents.

  • Entering an along-rafter overhang where the input expects horizontal projection.
  • Confusing the full span with one rafter's horizontal run.
  • Mixing a pitch ratio with an angle in degrees.
  • Including the overhang in the run and then adding it again as the separate overhang input.
  • Assuming geometric length determines a structurally suitable member size.
  • Rounding intermediate angle or cosine values too early.

Common questions

Is horizontal overhang the same as sloped rafter extension?

No. Horizontal overhang is the level projection entered in the calculator. The calculator divides it by the cosine of the roof angle to obtain the longer distance along the slope.

Why does the simple model use half the span as run?

For its symmetrical roof geometry, one common rafter covers the horizontal distance from an outside wall line to the central ridge line, which is half the entered full span.

Does total geometric length include rafter cuts and structural sizing?

No. Ridge and bearing cuts, fascia and trimming details, loads, spans, material sizing, connections, and applicable requirements need separate project-specific verification.

Sources

  1. Wood-Frame House Construction (Agriculture Handbook 73) · U.S. Department of Agriculture

    Describes roof slope as vertical rise per 12 units of horizontal run and discusses rafters, overhangs, ridge conditions, and roof framing. Used here for established terminology, not as a current design or compliance standard.