Rafter Calculator
A rafter calculator is a carpentry construction tool used to determine the dimensions of roof framing members. Based on the geometry of a gable roof, it treats the horizontal half-span (including any overhang) and the vertical rise as the two perpendicular sides of a right triangle. The calculator applies the Pythagorean theorem to determine the precise diagonal length of the rafter board. It also calculates the vertical rise from the wall plate to the ridge and converts the pitch into an exact angle in degrees. Carpenters and builders use this calculator to estimate lumber quantities and mark cuts.
Calculate rafter length, roof rise, and pitch angles for residential roof framing. Supports common pitches (e.g. 4/12, 6/12, 12/12) and custom profiles.
Quick Answer
Estimate roof rafter dimensions. Enter the building width, roof pitch, and overhang to calculate total rafter length, vertical rise, and pitch angle.
ESTIMATED RAFTER LENGTH
14 ft 6.4 in
Pitch: 6/12 · Angle: 26.6°
Examples
24 ft building, 6/12 pitch, no overhang
Run = 12 ft · Rise = 6 ft · Rafter Length = sqrt(12² + 6²) = 13.42 ft (13 ft 5 in)
24 ft building, 6/12 pitch, 12 in overhang
Total Run = 13 ft · Total Rise = 6.5 ft · Rafter Length = sqrt(13² + 6.5²) = 14.53 ft (14 ft 6.4 in)
30 ft building, 4/12 pitch, 18 in overhang
Total Run = 16.5 ft · Total Rise = 5.5 ft · Rafter Length = sqrt(16.5² + 5.5²) = 17.39 ft (17 ft 4.7 in)
How it works
The calculator uses the building width, roof pitch, and overhang to determine the horizontal run and vertical rise of the rafter, then applies the Pythagorean theorem.
Rafter Length Formula
Rafter Length = sqrt(Run² + Rise²)
Run and Rise Equations
- Run = (Building Width / 2) + Overhang
- Rise = Run × (Pitch / 12)
Anatomy of a Roof Frame
Framing a gable roof requires understanding several terms:
- Ridge Board: The horizontal beam at the peak of the roof where the top ends of the rafters meet.
- Wall Plate: The top horizontal framing member of the wall where the bottom of the rafter rests.
- Bird's Mouth Cut: A triangular notch cut into the rafter so that it fits flat against the top wall plate.
- Plumb Cut: The vertical cut at the top of the rafter that rests against the ridge board.
Practical Carpentry Considerations
When ordering lumber, always round up the calculated rafter length to the nearest standard board length (typically even lengths like 14, 16, or 18 feet). Additionally, remember that the calculator gives the line length from the ridge to the tail. In practice, you must subtract half of the thickness of the ridge board (typically 3/4 inch for a standard 2x ridge board) from the top plumb cut to ensure a tight fit.
Related tools
Check out our other construction and home design estimators, such as the Tile Calculator for flooring plans, and the Stair Calculator to compute riser and run dimensions.
Related Calculators
More tools from Home



