How to use the rafter calculator
- Choose feet or meters.
- Enter the building span (outside wall to outside wall) and the ridge board thickness, or enter the rafter run directly.
- Give the slope as a pitch (inches of rise per 12 inches of run), a total rise, or an angle.
- Enter the horizontal eave overhang to include the rafter tail.
How the calculation works
A common rafter forms the hypotenuse of a right triangle: the horizontal run is one leg and the vertical rise is the other. For a symmetrical gable roof the run is half the span, less half the thickness of the ridge board that the rafters bear against.
The rafter length then follows from the Pythagorean theorem. The overhang is converted from a horizontal projection to a length along the slope by multiplying by the slope factor (rafter length ÷ run). The plumb cut at the ridge is made at the roof angle; the seat (level) cut is 90° minus that angle.
Formula
Worked example
24 ft span, 6/12 pitch, 1 ft overhang
Run = 12 − 0.0625 (half of 1½ in) = 11.9375 ft. Rise = 11.9375 × 6 ÷ 12 = 5.969 ft.
Rafter length = √(11.9375² + 5.969²) = 13.347 ft (13′ 4-3/16″). Slope factor = 1.1180, so the 1 ft overhang adds 1.118 ft. Total ≈ 14.465 ft (14′ 5-9/16″). Roof angle = 26.57°.
Assumptions and limitations
- Lengths are theoretical line lengths. Actual cutting depends on the birdsmouth depth, rafter width, tail cut style and fascia details.
- Assumes a symmetrical gable roof with walls of equal height. Hip, valley and jack rafters need different calculations.
- This calculator does not size rafters. Rafter size, species, grade and spacing must come from span tables in your building code or from an engineer, based on snow, wind and dead loads.
Frequently asked questions
What does a 6/12 roof pitch mean?
The roof rises 6 inches for every 12 inches of horizontal run. That is an angle of about 26.6°.
How do I convert roof pitch to degrees?
Angle = arctan(pitch ÷ 12). For example, 4/12 = 18.43°, 8/12 = 33.69° and 12/12 = 45°.
Why subtract half the ridge board?
Rafters meet the face of the ridge board, not the centerline of the building, so each rafter’s run is shortened by half the ridge thickness.
What lumber length should I buy?
Buy the next stock length longer than the total rafter length, leaving room for the plumb cut and tail. For example, a 14′ 5″ total usually means 16 ft lumber.