Calculate rafter length, roof pitch angle, ridge height, overhang, plumb cut, and bird's mouth seat cut — with a live cross-section diagram.
Enter span, pitch, and overhang to compute all rafter measurements
Full width wall-to-wall
Labeled rise, run, span, overhang, and pitch angle
Total Rafter Length
Pitch Angle
Ridge Height (Rise)
Plumb Cut
Seat Cut (Bird's Mouth)
Slope Factor
| Pitch | Angle | Slope Factor | Category | Typical Use |
|---|
Learn more about this calculator and how to use it
At thecalculators.net, you will find free tools built for real-world construction tasks. Planning a roof without accurate rafter measurements is one of the most expensive mistakes a builder can make. A single miscalculation can cause structural failure, wasted lumber, and costly rework. Whether you are a DIY homeowner framing a shed or a professional contractor pricing a new build, getting your rafter lengths right the first time saves money and time.
A rafter calculator is a digital tool that computes the exact length of roof rafters based on the span of your building, the desired roof pitch, and the overhang. It uses the Pythagorean theorem and standard roofing geometry to deliver results in feet, inches, and fractions so you can cut lumber accurately without trial and error.
Unlike manual calculation, an online rafter calculator eliminates arithmetic errors, handles fractional inches automatically, and lets you adjust variables like pitch and overhang in seconds.
The core formula behind every rafter length calculation is rooted in basic geometry.
Featured Snippet Block: A rafter calculator uses the Pythagorean theorem to find the length of a roof rafter. The formula is: Rafter Length = √(Run² + Rise²). Run is half the building span. Rise equals Run multiplied by the pitch fraction. The result gives you the structural rafter length before adding any overhang or tail extension.
The key variables are:
|
Term |
Definition |
Example Value |
|
Span |
Total width of the building |
24 feet |
|
Run |
Half the span (one side of the roof) |
12 feet |
|
Pitch |
Rise per 12 inches of run (written as X/12) |
6/12 |
|
Rise |
Vertical height from wall plate to ridge |
6 feet |
|
Rafter Length |
Diagonal distance from ridge to wall plate |
13.42 feet |
|
Overhang |
Horizontal extension past the wall |
1.5 feet |
The full formula sequence:
1. Rise = Run × (Pitch ÷ 12)
2. Rafter Length = √(Run² + Rise²)
3. Overhang Length = √(Overhang² + (Overhang × Pitch ÷ 12)²)
4. Total Rafter = Rafter Length + Overhang Length
Let us walk through a complete example using a standard residential roof.
Given values:
· Building span: 28 feet
· Roof pitch: 8/12
· Overhang: 18 inches (1.5 feet)
Step 1: Calculate Run Run = Span ÷ 2 = 28 ÷ 2 = 14 feet
Step 2: Calculate Rise Rise = Run × (Pitch ÷ 12) = 14 × (8 ÷ 12) = 14 × 0.6667 = 9.333 feet
Step 3: Calculate Rafter Length (no overhang) Rafter Length = √(14² + 9.333²) = √(196 + 87.11) = √283.11 = 16.83 feet
Step 4: Calculate Overhang Rise Overhang Rise = 1.5 × (8 ÷ 12) = 1.5 × 0.6667 = 1 foot
Step 5: Calculate Overhang Rafter Length Overhang Rafter = √(1.5² + 1²) = √(2.25 + 1) = √3.25 = 1.80 feet
Step 6: Total Rafter Length Total = 16.83 + 1.80 = 18.63 feet (18 feet 7.5 inches)
This is the cut length for each common rafter in your roof. You will need one rafter for each side of every rafter pair, so multiply by the total rafter count for your lumber order.
Using an online rafter calculator takes less than two minutes once you have your measurements ready. Here is exactly how to get your numbers.
|
Input Field |
What to Enter |
Tips |
|
Building Span |
Total width of the structure in feet |
Measure from outside wall to outside wall |
|
Roof Pitch |
Rise over 12 inches of run |
Check plans or use a pitch gauge on an existing roof |
|
Eave Overhang |
Horizontal overhang distance |
Common values: 12 to 24 inches |
|
Unit Preference |
Feet and inches or metric |
US residential almost always uses feet/inches |
|
Rafter Count |
Number of rafters per side |
Determined by rafter spacing (typically 16 or 24 inches on center) |
Before you enter anything, have your building plans or actual measurements in hand. Estimating span from memory leads to lumber waste.
After calculation, the tool returns several values. Understanding each one prevents ordering errors.
Common Rafter Length: This is the diagonal cut length from the ridge board to the wall plate. It does not include the overhang unless you entered an overhang value.
Total Rafter Length with Overhang: The full board length you need to purchase before making any bird's mouth cut.
Ridge Board Length: For a simple gable roof, the ridge is equal to the building length. Some tools calculate this separately.
Board Feet (Lumber Volume): Some calculators convert rafter length into board feet so you can price your lumber order directly. If you are estimating material costs, this figure is useful alongside the budget estimator calculator.
Number of Boards: Total rafters needed based on your spacing and building length.
A homeowner is building a 12 × 16 foot storage shed with a 4/12 pitch and 12-inch overhangs.
· Span: 12 feet | Run: 6 feet
· Rise: 6 × (4 ÷ 12) = 2 feet
· Rafter Length: √(6² + 2²) = √(36 + 4) = √40 = 6.32 feet
· Overhang Rise: 1 × (4 ÷ 12) = 0.333 feet
· Overhang Length: √(1² + 0.333²) = √(1.11) = 1.054 feet
· Total Rafter: 7.37 feet (7 feet 4.5 inches)
Rafters will be spaced 24 inches on center along 16 feet of building length, giving 9 pairs (18 rafters total). Buying 10-foot 2x6 boards gives adequate length with room for the bird's mouth cut.
A contractor is framing a cathedral ceiling addition with a 12/12 pitch (45-degree angle) and a 24-inch overhang over a 20-foot span.
· Run: 10 feet | Rise: 10 × (12 ÷ 12) = 10 feet
· Rafter Length: √(10² + 10²) = √200 = 14.14 feet
· Overhang Rise: 2 × (12 ÷ 12) = 2 feet
· Overhang Length: √(2² + 2²) = √8 = 2.83 feet
· Total Rafter: 16.97 feet (16 feet 11.6 inches)
At this steep pitch, standard 2×8 rafters are typically required per IRC span tables. The contractor would pair this calculation with the plywood calculator to estimate roof sheathing needs.
Always account for the bird's mouth cut. The bird's mouth is the notch cut into the rafter bottom that sits on the wall plate. Most standard bird's mouth cuts remove about 1.5 to 2 inches of height from the rafter tail, which does not affect the rafter length calculation but does affect lumber selection. Choose boards with enough width to accommodate the notch without removing more than one-third of the rafter depth.
Use the right pitch for your climate. According to the International Residential Code (IRC, 2021 edition), roofs in heavy snow-load areas must have a minimum pitch of 3/12 or greater to prevent ice dam accumulation and excessive dead load. Low-slope roofs in high-snow regions are a structural liability.
Verify lumber availability in your total rafter length. Standard dimensional lumber comes in 2-foot increments: 8, 10, 12, 14, 16, 18, and 20 feet. If your total rafter length is 14.6 feet, you need 16-foot boards. Always round up to the next available board length.
Calculate for hip and valley rafters separately. Common rafters follow the formula above. Hip and valley rafters run diagonally across the roof corner and require a different multiplier. The diagonal factor for hip/valley rafters is typically 1.414 times the common rafter run.
Order at least 10 percent extra lumber. Waste from cuts, defects, and errors typically runs 8 to 12 percent on rafter framing. A good rule: calculate your exact board count, then add 10 percent and round up to the nearest whole number. This pairs well with planning your full material estimate using the concrete calculator for your foundation and the insulation calculator for the finished roof assembly.
Double-check your pitch with a speed square on site. Even if the plans say 6/12, actual as-built conditions sometimes vary. Measure the pitch directly on the existing structure before cutting replacement rafters.
Mistake 1: Confusing span and run. This is the most common error beginners make. The span is the full width of the building. The run is half that value. Entering the full span where the run is expected will double your rise and produce a rafter nearly twice as long as it should be.
Mistake 2: Forgetting the ridge board thickness. A standard 1.5-inch ridge board means each rafter actually terminates 0.75 inches (half the ridge thickness) closer to center than the theoretical peak. On most residential roofs this difference is small enough that carpenters account for it with a plumb cut angle rather than adjusting the rafter length. On engineered roofs or long spans, it matters more.
Mistake 3: Ignoring the difference between roof pitch and roof slope. Pitch is the ratio of rise to span (total width). Slope is the ratio of rise to run (half width). A slope of 6/12 equals a pitch of 6/24 (or 1/4 pitch). Most modern construction professionals use slope, not pitch, when specifying roofs. Your rafter calculator uses slope notation (rise per 12 inches of run).
Mistake 4: Not accounting for the rafter tail. The overhang calculation must include the rise component too. Many builders try to add overhang by simply adding horizontal inches to the rafter length, which underestimates the diagonal tail length. Always use the Pythagorean formula for the overhang section as shown in the worked example above.
Mistake 5: Using nominal vs. actual lumber dimensions. A 2×8 board is actually 1.5 × 7.25 inches in actual dimensions. When calculating bird's mouth cuts or checking rafter depth requirements against span tables, always use the actual size, not the nominal label.
Mistake 6: Skipping the span table check. Rafter length alone does not tell you if a board size is structurally adequate. A 2×6 rafter spanning 18 feet will fail under standard loading. Always cross-reference your rafter span against the IRC span tables for your lumber species and grade. According to the 2023 NAHB Cost of Construction Survey, framing errors account for approximately 9 percent of all residential construction rework costs.
Rafter calculations rarely happen in isolation. A full roofing or framing project involves multiple material estimates. Here are the tools that pair most naturally with your rafter work.
|
Tool |
When to Use It |
Link |
|
Plywood Calculator |
Estimating roof sheathing after rafter count is known |
|
|
Decking Calculator |
Calculating decking boards if adding a rooftop deck |
|
|
Insulation Calculator |
Sizing attic or rafter bay insulation after framing |
|
|
Drywall Calculator |
Interior ceiling drywall under the rafter bays |
|
|
Concrete Calculator |
Foundation volume for the structure being framed |
|
|
Rebar Calculator |
Foundation or slab reinforcement |
|
|
Budget Estimator Calculator |
Total project cost once material quantities are known |
A complete framing workflow typically starts with foundation (concrete and rebar), moves through structural framing (rafter calculator), then sheathing (plywood), insulation, and finally interior finishing (drywall). Using the right calculator at each stage keeps your material ordering accurate from the ground up.
Getting your rafter lengths right is not optional. It determines whether your lumber order is accurate, your cuts are clean, and your roof structure is safe. The rafter calculator takes the guesswork out of one of framing's most geometry-heavy tasks by applying the Pythagorean theorem automatically, handling pitches from 1/12 to 24/12, and accounting for overhangs in seconds.
Your action steps:
1. Measure your building span from outside wall to outside wall
2. Confirm your roof pitch from your plans or measure on-site
3. Decide your overhang based on climate, aesthetics, and code requirements
4. Run the rafter calculator to get your exact rafter length and board count
5. Cross-reference lumber size against IRC span tables for your load zone
6. Order lumber rounded up to the nearest standard length with 10 percent waste factor
From there, continue your estimate with sheathing using the plywood calculator, then move to insulation with the insulation calculator, and close out your full project budget with the budget estimator calculator.
Accurate framing starts with accurate numbers. Run your calculation before you run your saw.
Promote your business here.
Contact us for advertising.
Promote your business here.
Contact us for advertising.
Promote your business here.
Contact us for advertising.