Skip to main content

Rafter Length Calculator — Cut Angles & Lumber List

Enter span, pitch and overhang: get the rafter length to cut, plumb and seat cut angles, the bird's mouth and an optimized lumber list.

A rafter on a wall plate: run, rise, line length, plumb cut at the ridge and the bird's mouth seat
Two plumb cuts and a bird's mouth: the three things a rafter length has to account for

The rafter length is the number every roof framing job starts with, and it is the one most often bought short. The line length you get from the pitch is not the board you need: both ends are plumb cuts, and two parallel plumb cuts across a deep board are offset along it. On a 2x8 at 6/12 that offset is 3 5/8 in — per rafter.

This calculator gives you the rafter length to cut, both cut angles and the bird’s mouth, and then the whole roof as a cut list: rafters, barge rafters, ridge, collar ties, counter battens and tile battens — on hip and L-shaped roofs also the hip, jack, valley and valley jack rafters — packed into the lumber you actually buy.

The default is a 24 ft span, 40 ft long gable at 6/12 with 12 in eaves and gable overhang, 2x8 rafters at 24 in on center, a 2x10 ridge board and a 3 1/2 in seat. The rafter comes out at 14 ft 9 3/16 in to cut, plumb cut 26.6° and seat cut 63.4° from square, notch 1 5/8 in. The order list: 46 × 16 ft 2x8, 3 × 16 ft 2x10 and 11 × 12 ft 2x6 — 1193 board feet at 6.9 % waste.

How do you use this calculator?

  1. Pick the market and the roof

    US reads and shows feet-inches and pitch in x/12 (type 24’ or 24-6 or 6 1/2”). UK switches to millimetres, degrees and tile battens. Then the shape: gable, shed, hip, L-shaped gable or L-shaped hip. A hip or L button loads that shape’s example, which you then overwrite with your own numbers.

  2. Enter what you measured

    Span over the outside of the walls, the building length, pitch, eaves and gable overhang, rafter spacing, rafter and ridge size, and the seat — the width of the wall plate the rafter bears on.

  3. Read the rafter

    Three drawings to scale sit beside the form: the side view (a section across the span — rafters with their bird’s mouth, ridge, collar ties, counter battens and battens), the top view (every rafter at its spacing, the barge rafters, ridge joints, batten rows and their joints) and the rafter detail with the cut length and both angles. On hip and L-shaped roofs a fourth view, the hip detail, draws the hip rafter with its side cuts and the longest jack rafter, and the numbers in the top view are the rows of the cut list. Drag a gold handle — pitch, span, overhangs, building length, collar height — or click a dimension and type a new value; the form follows. The line length, run, rise, heel height and notch depth sit underneath.

  4. Order the lumber

    The cut list is live. The order list is a real optimization of those pieces into your stock lengths; recalculate it after a change, or open everything in the app. Print / PDF puts the side view, the top view, the inputs, the cut list and the order list on one A4 sheet; the browser’s print dialog also saves it as a PDF. If the inputs changed since the last calculation, the sheet asks you to recalculate instead of printing an outdated order list.

How does it calculate the rafter?

Everything is measured from the outside corner of the wall plate, where the bird’s mouth heel meets the seat — the measuring line.

  • Run — on a gable roof, half the span minus half the ridge board: 12 ft − 3/4 in = 11 ft 11 1/4 in in the example. On a shed roof the run is the whole span.
  • Line length — run ÷ cos(pitch). At 6/12 every foot of run is √(12² + 6²) ÷ 12 = 1.118 ft of rafter, so 11 ft 11 1/4 in becomes 13 ft 4 3/16 in.
  • Rafter length to cut — (run + eaves) ÷ cos(pitch), plus depth × tan(pitch) for the two plumb cuts: 14 ft 9 3/16 in, rounded up, never down.
  • Cut angles — plumb cut = pitch, seat cut = 90° − pitch, both from square.
  • Bird’s mouth — heel height = seat × tan(pitch) = 1 3/4 in; notch depth square to the rafter = seat × sin(pitch) = 1 5/8 in.

Rafters per side are one at each gable end plus one every spacing, so the last gap is never wider than your spacing: 40 ft at 24 in gives 21 per side, 42 in all, plus four barge rafters for the gable overhang.

How are the ridge, collars and battens cut?

Ridge. The ridge runs the building length plus both gable overhangs. If that is longer than your stock, it is joined over a rafter pair: 42 ft from 16 ft boards comes out as 15 ft, 16 ft and 11 ft.

Collar ties. Set at a share of the rise (67 % by default) on every n-th rafter pair, with the ends cut to the roof slope so they sit flush with the rafter tops: 11 ties of 11 ft 11 7/16 in in the example.

Tile battens (UK profile). The rows per slope are counted from the first batten at the eaves to the top batten under the ridge, at an equal gauge no wider than the maximum you enter. Each row is then cut so that every joint lands over a rafter, every piece spans at least three rafters and 1.2 m, and no rafter carries a joint in more than one of any four rows — the BS 5534 rule. Those are constraints, not suggestions: the pieces are generated to satisfy them before the optimizer sees them.

Sheathing (US profile). Instead of battens the US profile estimates 4×8 panels laid across the rafters with staggered rows: 46 sheets for the example. It is a count, not a sheet layout.

How does it handle hip and L-shaped roofs?

A hip roof replaces the gable ends with sloping planes. Where two planes meet, a hip rafter runs from the wall corner up to the ridge, and the rafters on the hip end and on the long sides near the corners get shorter step by step: the jack rafters, each with the same plumb cut and bird’s mouth as a common rafter and a side cut where it lands on the hip. An L-shaped roof adds a wing; where the wing meets the main block a valley rafter runs in the inside corner, carrying the valley jacks.

The calculator lists all of them by role, each with its length, plumb cut and side cut (the saw tilt for the cheek cut), and the order list packs them with the commons. The wing of an L has the same span and pitch as the main block; the wing position picker only mirrors the drawings.

The US hip example — 24 ft span, 40 ft long, 6/12, 12 in eaves, 2x8 at 24 in on center, 2x10 ridge board — gives 18 common rafters at 14 ft 9 3/16 in, 4 hip rafters at 19 ft 7 1/2 in with a hip pitch of 19.5° and a 45° saw tilt for the side cuts, and 40 jack rafters, left and right, from 12 ft 6 7/8 in down to 3 ft 7 9/16 in in steps of 26 7/8 in. The order list: 38 × 20 ft 2x8 and 2 × 16 ft 2x10 — 1067 board feet at 13.6 % waste.

One stock length per section. The order list buys one length for each section. When the hip rafters share the rafter section, the whole section is ordered in the hip stock length: 20 ft boards for every 2x8 in the example above, commons and jacks included. Enter a different hip / valley stock length and the list follows.

L-shaped example. The US L-shaped hip example keeps the main block at 24 × 40 ft and adds a 16 ft wing: 22 common rafters, 5 hip rafters, 50 jack rafters, one valley rafter at 19 ft 7 1/2 in and 12 valley jacks from 2 ft 5 5/16 in to 13 ft 7 7/16 in. The order list: 52 × 20 ft 2x8 and 3 × 16 ft 2x10 — 1467 board feet at 10.3 % waste.

Shared mitre cuts. Two pieces whose angled ends match can come out of one board with a single saw cut. On hip and L-shaped roofs the order list computes the job both ways, the Shared mitre cuts switch picks one, and the other stays visible as a measured line. On the UK hip example (8000 × 10000 mm, 35°, 47×150 rafters at 600 mm, 25×50 battens at 4800 mm, 3 mm kerf) the shared cuts save one batten: 122 lengths instead of 123, with 19 shared cuts. In these examples only the battens share cuts; the US examples have no battens, so both results are the same 40 and 55 boards.

Battens on every plane. On the UK profile the tile battens run on every roof plane, including the triangular hip ends, and end on the hip or valley line. Near the hip the rows get short; where a piece can no longer span three rafters or the joints cannot be staggered, the calculator shows a warning, and longer battens fix it.

When you open a hip or L-shaped list in the app, the angles travel with it: Wood mode receives every piece with its end cuts, and the shared-cuts switch is set the way you left it.

What are the rules in your market?

The calculator is geometry. The size of the rafter, the spacing that span allows and the panel or batten you need are set by your local code — the calculator links them and never copies their tables.

  • US — IRC R802.4.1 rafter span tables; IRC R802.7.1 for end notches (≤ ¼ of the depth); APA span ratings for roof sheathing.
  • UK — BS 5534 for slating and tiling and the batten rules (Marley’s setting-out guide); BS EN 338 / BS EN 14081 strength classes; TDUK C24 span tables; Eurocode 5 (BS EN 1995-1-1).

The calculator does not check whether a section is strong enough for the span, snow or wind load, and it never will. Size the rafters from the span tables above or have them designed; take the cut list from here. On hip and L-shaped roofs that includes the hip and valley rafters, which carry the jack rafters.

Common mistakes

Buying the line length. The line length is measured on the measuring line; the board has to hold both plumb cuts as well. On deep rafters at steep pitches the difference is several inches per rafter.

Measuring the span inside the walls. The run starts at the outside of the wall plate, where the bird’s mouth heel sits. Measure inside and every rafter is short by the wall thickness.

Forgetting the ridge board. On a gable roof half the ridge thickness comes off each run. Leave it in and every rafter is 3/4 in long at the ridge.

Cutting the seat too deep. A wider seat makes a deeper notch. Over a quarter of the depth the US code says no — the calculator warns.

Joining battens between rafters. A batten joint hanging in mid-air is the classic failure the batten rules exist for. Here it cannot happen: joints are only ever generated over a rafter.

When should you not use this?

On roofs the calculator does not draw: an L whose wing has a different span or pitch, a T or U plan, dormers, or more than one wing. On trussed roofs, which are designed and built in the truss plant. And whenever the question is “is this rafter big enough” — that is a span-table or engineering question, not a cut list.

If you already have the cut list and only need it packed into stock lengths, the wood cutting calculator starts there.

A rafter on a wall plate: run, rise, line length, plumb cut at the ridge and the bird's mouth seat
Two plumb cuts and a bird's mouth: the three things a rafter length has to account for

Frequently asked questions

How do you calculate rafter length?
Take the run, which is half the span minus half the ridge board on a gable roof, add the eaves overhang and divide by the cosine of the pitch. That is the length between the two plumb cuts. The board you cut it from must be longer by the rafter depth times the tangent of the pitch, because the two plumb cuts are offset along the board.
What are the plumb cut and seat cut angles?
Measured from square across the board, the plumb cut equals the pitch and the seat cut is 90 degrees minus the pitch. A 6/12 roof is 26.6 degrees, so the plumb cut is 26.6 and the seat cut 63.4 degrees.
How deep can the bird's mouth be?
The US code limits a notch at the end of a sawn rafter to one quarter of its depth (IRC R802.7.1). The calculator shows the notch depth and warns on the US profile when the seat you enter cuts deeper than that.
What length lumber should I buy for rafters?
At least the rafter length to cut that the calculator shows, which already includes the plumb-cut offset. The order list then picks how many of the stock lengths you entered are needed, with the barge rafters, ridge and collars packed in.
Does the calculator tell me what size rafter I need?
No. It is geometry only. Whether a 2x8 spans your roof depends on species, grade, spacing, snow and wind, which is what the span tables in IRC R802.4.1 or, in the UK, the span tables based on BS EN 338 and Eurocode 5 answer. The page links them; ask your inspector or a structural engineer when in doubt.
Why are the battens cut to odd lengths?
Because a batten may only be joined over a rafter. Every piece is a whole number of rafter spacings, spans at least three rafters, and the joints move along from row to row so they do not all land on the same rafter.
Does it work out hip and valley rafters?
Yes, for a hip roof and for an L-shaped roof whose wing has the same span and pitch as the main block. The cut list then carries the hip rafters, the left and right jack rafters in a falling series of lengths, the valley rafter and the valley jacks, each with its length, plumb cut and side cut, and the order list packs them with the commons.
What does the shared mitre cuts switch do?
On hip and L-shaped roofs, two pieces whose angled ends match can come out of one board with a single saw cut. The switch picks between the order list with and without those shared cuts; both are computed on the same list, so the other result is shown next to it.

Related