Hip and Valley Rafter Calculator

Updated November 12, 2026 · buildcalc.io editorial team

Hip and valley rafter calculator

1. Roof (equal pitch on both planes, walls at 90°)
Hip or valley length
–
With overhang
–
Common rafter length
–
Hip run (plan)
–
Hip pitch
–
Hip angle
–
Jack rafter step
–
Jack rafter lengths

    Enter the roof pitch and the common run (half the building width, from the wall plate line to the ridge). The calculator returns the hip or valley length, its plan run, its pitch and angle, and the length of every jack rafter. It assumes a roof with the same pitch on both planes and walls meeting at 90 degrees.

    The geometry

    In U.S. building codes (including IRC Chapters 2, 8 and 9) and carpentry practice, roof slope is stated as vertical rise per horizontal run using 12 inches as the base unit—so 6/12 means 6 inches of vertical rise for every 12 inches of horizontal run (using 17 inches of horizontal run as the framing-square base instead for regular 90-degree hips and valleys, since 12 × √2 ≈ 16.97 in). In standard stick-framing terminology per IRC Chapter 8 and the AWC Wood Frame Construction Manual (WFCM), a hip rafter forms the external diagonal ridge where two adjacent sloping roof planes meet over an outside building corner, whereas a valley rafter forms the internal diagonal channel where two intersecting roof planes meet over an inside corner.

    Seen from above, the hip crosses the corner on the diagonal of a square, at 45 degrees to both walls. The diagonal of a square is √2 (1.4142) times its side, so the hip’s horizontal run is longer than the common run by that factor, while its rise is the same as the common rafter’s.

    common rafter = run × √(1 + (pitch ÷ 12)²) rise = run × pitch ÷ 12 hip run = run × √2 hip length = √(hip run² + rise²) hip angle = atan(rise ÷ hip run) jack step = spacing × √(1 + (pitch ÷ 12)²)

    The result is a length along the centreline of the rafter, with no deduction for the ridge board, no birdsmouth and no tail. Add the overhang in the calculator or by hand, then deduct half the ridge thickness at the top as your plans require.

    Worked example 1: a 6/12 hip

    The common run is 12 ft, so the building is 24 ft wide.

    • rise = 12 × 6 ÷ 12 = 6 ft
    • hip run = 12 × 1.4142 = 16.97 ft
    • hip length = √(16.97² + 6²) = √(288 + 36) = 18.00 ft
    • common rafter = 12 × 1.1180 = 13.42 ft

    The hip is 1.5 times the common run on this pitch. The hip angle is atan(6 ÷ 16.97) = 19.47 degrees, and its pitch is 6 ÷ 1.4142 = 4.24 inches per 12 inches of hip run.

    Worked example 2: a 12/12 hip

    • rise = 12 ft, hip run = 16.97 ft
    • hip length = √(288 + 144) = 20.78 ft
    • hip angle = atan(12 ÷ 16.97) = 35.26 degrees

    Steeper roofs lengthen the hip relative to the plan because the rise grows while the plan run stays fixed.

    Worked example 3: jack rafters

    Jack rafters run parallel to the common rafters on the same roof slope, framing from the wall top plate up to the diagonal face of a hip rafter (hip jacks) or from the ridge down to a valley rafter (valley jacks), each one shorter than its neighbour by a uniform common difference. With 16 inch on-centre spacing on the 6/12 roof, that common difference step is 16 × 1.118 = 17.89 inches. The calculator lists them: the first jack is (12 − 1.333) × 1.118 = 11.93 ft, the second 10.44 ft, and so on, eight in all. At 24 inch spacing the step is 26.83 inches. Because a regular hip collects shortened hip-jack rafters bearing against both of its compound-bevelled faces, double the jack list for each hip corner.

    Worked example 4: with overhang

    A 12 inch horizontal overhang on the common rafters adds 12 × 1.4142 = 16.97 inches (1.414 ft) of horizontal run to the hip. Along the slope that is 1.414 × (18.00 ÷ 16.97) = 1.5 ft, so the hip with overhang is 19.5 ft. Enter the overhang and read the “with overhang” value. Always cut one rafter first, test it in place, then use it as a pattern.

    Hip length per foot of common run

    For a quick check, the hip length per foot of common run is √(2 + (pitch ÷ 12)²). These values come from the same formula:

    Pitch Hip length per ft of run Hip angle Hip for a 10 ft run
    4/12 1.4530 13.26° 14.53 ft
    6/12 1.5000 19.47° 15.00 ft
    8/12 1.5635 25.24° 15.64 ft
    10/12 1.6415 30.51° 16.42 ft
    12/12 1.7321 35.26° 17.32 ft

    Multiply by your common run in feet to get the hip, then add overhang. The 6/12 row is exact at 1.5 because √2.25 is 1.5. Compare the calculator result against this table as a sanity check, and round the finished length up to the next stock length your supplier carries.

    Where this stops working

    Roofs with different pitches on two planes, additions that join at an angle other than 90 degrees, and valleys between roofs of different widths all need their own geometry. The √2 factor only describes the diagonal of a square. For a rectangle, the valley’s plan run is the diagonal of a rectangle formed by the two runs, which the calculator does not attempt. Use a framing method for those cases or ask a roofer or designer.

    What the code requires

    Rafter size and span come from span tables and structural engineering (such as the AWC Wood Frame Construction Manual and NDS), which this geometry page does not provide. One prescriptive requirement is stated directly in IRC R802.4.3: hip and valley rafters shall be at least 2 inches nominal in thickness and not less in depth than the diagonal plumb-cut end of the abutting rafters—which typically bumps a hip or valley member one or two nominal lumber depths deeper than the common rafters so the plumb cheek cuts have full bearing. Under R802.4.3 they must also be supported at the ridge by a vertical brace to a load-bearing partition, or be engineered as structural hip/valley beams to carry and distribute the tributary load from the jack rafters. Your local code, the adopted edition and your stamped design drawings control what you build; keep in mind when renovating historic timber structures that older hand-framed roofs often used tapered or rough-sawn hip timbers that do not match modern dressed lumber dimensions.

    Common mistakes

    • Using the common rafter length for the hip. The hip is longer because its run is the diagonal.
    • Mixing up run and span. The common run is half the span.
    • Using this for unequal pitches. The √2 shortcut only holds when both planes share a pitch and the walls meet at 90 degrees.
    • Forgetting backing and deductions. Real hips are cut with side bevels and ridge deductions that depend on your framing method.

    For plain rafters see the rafter length calculator, for factory-built framing the roof truss calculator, and for coverings the roofing underlayment calculator. The roofing hub lists the rest.

    PartnerJobsite Tool & Fastener Spec Strip
    Supplier links may earn a commission at zero extra cost to you · Disclosure
    15° Pneumatic / Cordless Coil Roofing Nailer

    Drives 1-1/4" galvanized coil nails flush with depth dial

    OSHA-Compliant Roof Fall-Protection Harness Kit

    Full-body harness, reusable roof anchor, 50 ft lifeline & rope grab

    Notched Shingle Tear-Off Shovel & Hook Blades

    Pries old shingles and pulls nails cleanly from roof deck

    Dimensional Lumber & LVL Section Properties (AWC NDS / PS 20)

    Nominal vs. actual dressed dimensions, cross-sectional area A, section modulus S, moment of inertia I, board-foot factor, and unit weights.

    Nominal Size Actual (b × d) Area A (in²) Section Mod. S (in³) Inertia I (in⁴) BF / lin ft Dry Wt (lb/ft)
    2x41.5" × 3.5"5.253.0635.3590.66671.28
    2x61.5" × 5.5"8.257.56320.79712.01
    2x81.5" × 7.25"10.87513.14147.6351.33332.64
    2x101.5" × 9.25"13.87521.39198.9321.66673.37
    2x121.5" × 11.25"16.87531.641177.97924.1
    4x43.5" × 3.5"12.257.14612.5051.33332.98
    4x63.5" × 5.5"19.2517.64648.52624.68
    6x65.5" × 5.5"30.2527.72976.25537.35
    1-3/4x9-1/2 LVL1.75" × 9.5"16.62526.323125.0341.66674.85
    1-3/4x11-7/8 LVL1.75" × 11.875"20.78141.13244.20726.06
    1-3/4x14 LVL1.75" × 14"24.557.167400.1672.33337.15

    Reference standard: AWC National Design Specification (NDS) Supplement & NIST PS 20. Click any column header to sort or click a highlighted preset pill inside the calculator to auto-fill values.

    PartnerHiring Out This Hip and Valley Rafter Job?
    Free quote matching · Zero PII stored on buildcalc.io · Disclosure

    Enter your ZIP or postal code to compare bids from vetted local licensed roofing contractors matched to your calculated scope.

    Frequently asked questions

    How do you calculate hip rafter length?

    On a roof with equal pitches and walls at right angles, the hip runs at 45 degrees in plan, so its horizontal run is the common run times 1.414. The hip length is the square root of the hip run squared plus the rise squared. For a 6/12 roof with a 12 ft common run that is √(16.97² + 6²) = 18.0 ft.

    Is a valley rafter the same length as a hip rafter?

    On a roof with equal pitch on both planes meeting at 90 degrees, yes: the valley has the same plan run, rise and length as a hip. Valleys that join roofs of different pitch or width need separate geometry.

    What size lumber does the IRC require for hip and valley rafters?

    IRC R802.4.3 says hip and valley rafters shall be not less than 2 inches nominal in thickness and not less in depth than the cut end of the rafter, and be supported at the ridge by a brace to a bearing partition or designed to carry that load.

    How much shorter is each jack rafter?

    Each jack is shorter than the one before by the spacing times the common rafter factor. At 16 inches on centre on a 6/12 roof the step is 16 × 1.118 = 17.89 inches.

    Sources

    1. 2021 International Residential Code, Chapter 8 Roof-Ceiling Construction, R802.4.3 Hips and valleys, International Code Council, accessed November 2026.
    2. Wood Frame Construction Manual (WFCM) for One- and Two-Family Dwellings & National Design Specification (NDS) for Wood Construction, American Wood Council, accessed November 2026.
    3. 2021 International Residential Code, Chapter 2 Definitions & Chapter 9 Roof Assemblies (roof slope in units of vertical rise per 12 units of horizontal run), International Code Council, accessed November 2026.