A rafter is always longer than the run it covers, and the gap grows fast with pitch — at 45° a rafter is 41% longer than the horizontal distance it spans. This does the trigonometry, counts the rafters and gives you the slope area for the covering.
Enter the run — that is wall to ridge horizontally, usually half the building width — then the pitch and the roof length.
Works in metric and US imperial — you choose at the start and can switch at any time. Every figure this calculator uses is published with its source, and the result comes with a printable order sheet. No account, no email, and nothing you type leaves your browser.
Related: Roofing calculator · Framing calculator · Joist calculator
All calculators · How to use them · The standards behind our figures
And the gap grows fast with pitch. At 30° a rafter is about 15% longer than the horizontal distance it covers; at 45° it is 41% longer. A 3 m run at 45° needs a 4.24 m rafter. This page does the trigonometry so the timber order is right — ordering to the run rather than the rafter length is the classic way to end up with a roof's worth of timber that is all too short.
Run is half the building width for a simple gable, measured horizontally from the outside of the wall plate to the centre of the ridge. Measuring the whole width is the common error and doubles the answer. Pitch goes in as degrees: if your roof is quoted as a US rise-over-run, convert first — 4/12 is 18.4°, 6/12 is 26.6°, 9/12 is 36.9°, and 12/12 is 45°.
The figure is the straight timber length including overhang. The birdsmouth and the ridge cut are not in it — setting out the seat cut at the wall plate and the plumb cut at the ridge is marking-out work done on the timber itself. Cut one template rafter, offer it up, check it, then use it to mark every other one; measuring each separately guarantees a wavy ridge. And remember minimum pitch is set by the covering: slate and plain tiles generally want 35° or more, interlocking concrete tiles can go to 17.5° or lower, and below about 10° you are into sheet materials.
Divide the run by the cosine of the pitch angle, then add the overhang. At 45 degrees that makes the rafter 41% longer than the run; at 30 degrees, about 15% longer. This calculator does it for you, but the arithmetic is worth knowing because ordering to the run is a common and expensive mistake.
The horizontal distance from the outside of the wall plate to the centre of the ridge — half the building width on a simple gable. Measuring the full width instead is the usual error.
6/12 is 26.6 degrees. For reference: 4/12 is 18.4, 9/12 is 36.9, and 12/12 is 45 degrees. Enter pitch in degrees on this page.
It depends on the covering. Slate and plain tiles generally want 35 degrees or more; interlocking concrete tiles can go to 17.5 degrees or lower; below about 10 degrees you are into sheet materials. Check the manufacturer's figure for the specific product.