A king post truss calculator works out the rafter length, king post height, and total truss height for a simple triangular roof frame. You enter the building width (span) and the roof pitch, and it returns the cut lengths and angles you need for the common king post truss geometry. This page gives you the formulas, a worked example, and the practical details that matter when you build one.
Formula
The king post truss is built around a single vertical post (the king post) that connects the peak of the truss to the center of the bottom chord (the tie beam). The geometry is two identical right triangles standing side by side.
For a truss with a total span S (the horizontal distance between the outer edges of the supports) and a roof pitch P (the angle of the rafter above horizontal, in degrees):
- Half-span H = S / 2 (the horizontal run of one rafter)
- Rafter length R = H / cos(P) (measured along the top edge of the rafter, from the peak to the outside of the wall)
- King post height K = H × tan(P) (measured from the top of the tie beam to the underside of the ridge/rafter intersection)
- Total rise T = K (same as king post height, since the king post sits on the tie beam)
- Plumb cut angle A = 90° − P (the vertical cut at the top of the rafter where it meets the ridge)
All lengths are in the same unit you enter (feet, meters, etc.). The formulas assume the truss is symmetrical and the bottom chord is horizontal.
Worked Example
Using the default values from the calculator: building width = 24 ft, roof pitch = 30°.
- Half-span H = 24 / 2 = 12 ft
- Rafter length R = 12 / cos(30°) = 12 / 0.8660 = 13.856 ft → 13.86 ft
- King post height K = 12 × tan(30°) = 12 × 0.5774 = 6.928 ft → 6.93 ft
- Total rise T = 6.93 ft (same as king post height)
- Plumb cut angle A = 90° − 30° = 60°
The calculator gives the same results: rafter 13.86 ft, king post 6.93 ft, rise 6.93 ft, and plumb cut 60°.
How a King Post Truss Works
A king post truss is one of the oldest and simplest structural frames. The top members (rafters) carry the roof load down to the walls, but they also push outward at the base. The bottom chord (tie beam) resists that outward thrust by acting in tension. The king post hangs from the peak and supports the middle of the tie beam, preventing it from sagging under its own weight and the ceiling load.
This arrangement is efficient for spans up to about 8–10 m (25–30 ft). Beyond that, the king post becomes very long and slender, and a queen post truss (two posts) or a more complex truss is usually needed.
The geometry is what makes the truss work: the angles and lengths are all fixed by the span and pitch. If you change the pitch, the rafter length and post height change accordingly. The calculator above gives you the basic cut lengths, but you still need to account for the thickness of the lumber and the type of joints (e.g., half-lap, mortise and tenon, or metal plates).
How to Use the Calculator: Step by Step
- Measure the building width (span) from outside of wall to outside of wall, or from bearing to bearing. This is the horizontal distance the truss must cover.
- Decide on the roof pitch. This is the angle of the rafter above horizontal, typically between 15° and 45° for most roofs. If you have a rise/run ratio, convert it to degrees: pitch angle = atan(rise / run).
- Enter those two numbers in the calculator. The result gives you the rafter length (centerline to centerline), the king post height, total rise, and the plumb cut angle.
- Add the roof overhang (eave) to the rafter length if you want the total rafter board length. The calculator does not include overhang.
- Subtract half the ridge board thickness (if you use one) from the rafter length, and adjust the king post height accordingly. The calculator gives theoretical centerline dimensions.
Common Mistakes and How to Avoid Them
- Mixing up pitch and slope. Pitch is often given as rise/run (e.g., 6/12) rather than degrees. To convert: angle = atan(rise / run). For 6/12, that’s atan(0.5) = 26.57°.
- Forgetting the overhang. The rafter length from the calculator is only to the outside of the wall. If you want an eave overhang, add that horizontal distance to the half-span before computing the rafter length.
- Using the full span instead of half-span. The rafter runs from the peak to the wall, so it’s based on half the span. Using the full span doubles the rafter length.
- Ignoring lumber thickness. The calculator gives centerline dimensions. When you cut the rafter, you need to account for the ridge board thickness (typically 1.5 in for a 2×) and the seat cut at the wall.
- Rounding too early. Round only the final answer, not intermediate values. If you round 13.856 to 13.9 and then use that for the king post, you’ll get a slightly off angle.
Reading the Results and What They Mean for Construction
The rafter length is the measurement along the top edge of the rafter from the peak to the outside of the wall plate. For a real rafter, you’ll need to add the length of the tail (overhang) and subtract the ridge thickness. The plumb cut angle is the angle at the top of the rafter where it meets the ridge or the opposite rafter. The seat cut (where the rafter sits on the wall) is the same angle as the pitch, measured from horizontal.
The king post height is the vertical distance from the top of the tie beam to the underside of the rafters at the peak. If you use a ridge board, the king post typically butts against the ridge, so you may need to add half the ridge thickness to the post length.
These dimensions are for the basic geometry. They do not include any camber (a slight upward bow in the tie beam), which is sometimes added to prevent sagging. Nor do they account for the actual lumber sizes, joint details, or load calculations.
Limitations and When to Consult a Professional
This calculator gives you the geometry of a king post truss, but it does not tell you if the truss is strong enough for your roof. The size of the members depends on the roof load (dead load + snow load + wind load), the species and grade of lumber, and the span. A 2×4 king post truss might be fine for a small shed, but a 30-foot garage needs engineered trusses or a professional structural design.
Building codes in most areas require that structural roof framing be designed by an engineer or be built from pre-engineered trusses. The calculator is a design aid for understanding the geometry, not a substitute for structural analysis. Always check local building codes and consult a qualified professional before building a truss that will carry a roof.
Also, the formulas assume a simple triangular truss with no collar ties, struts, or other reinforcements. If you add those, the geometry changes.
Alternatives to a King Post Truss
If the span is too long for a king post, or if you want more headroom, consider these alternatives:
- Queen post truss: Two vertical posts, each about a third of the way from the walls. Works for spans up to about 12 m (40 ft).
- Scissor truss: The bottom chord is angled upward, giving a vaulted ceiling. More complex to calculate.
- Attic truss: A truss with a raised bottom chord that creates a room in the attic. Requires a professional design.
- Pre-engineered metal plate trusses: Factory-built, designed by computer, and code-approved. Often the most economical for large spans.
For a simple shed or small outbuilding, a king post truss is often the most straightforward and cost-effective choice. For anything larger, or if you’re not confident in your carpentry skills, use a pre-engineered truss.
Frequently Asked Questions
What is the difference between a king post and a queen post truss?
A king post truss has a single central vertical post, while a queen post truss has two vertical posts placed symmetrically away from the center. Queen post trusses are used for longer spans because the two posts reduce the unsupported length of the tie beam.
How do I convert roof pitch from rise/run to degrees?
Use the formula: angle = atan(rise / run). For a 6/12 pitch, that’s atan(6/12) = atan(0.5) ≈ 26.57°. Most calculators have an atan (inverse tangent) function.
Does the calculator include the ridge board thickness?
No. The calculator gives centerline dimensions. To get the actual rafter length, subtract half the ridge board thickness from the calculated rafter length. For example, with a 1.5-inch ridge, subtract 0.75 inches.
Can I use this calculator for a metal building truss?
The geometry is the same, but metal trusses often use different connection details and may have a different profile (e.g., tapered rafters). Use the calculator for the basic triangle, but confirm the final dimensions with the metal truss manufacturer’s drawings.
What is the maximum span for a king post truss?
In practice, king post trusses are typically used for spans up to about 25–30 feet (8–9 m). Beyond that, the king post becomes too slender and the truss becomes inefficient. For longer spans, consider a queen post or a pre-engineered truss.
Why does the plumb cut angle equal 90° minus the pitch?
Because the rafter meets the ridge at the peak, and the ridge is vertical. The angle between the rafter and the vertical ridge is the complement of the pitch angle. So the plumb cut is 90° − pitch.
Related
Formula used
in span | Building width | ft | 24 | 1 | 100 in pitch | Roof pitch | ° | 30 | 1 | 60 out rafter | Rafter length | ft | (span / 2) / cosd(pitch) | 2 out king | King post height | ft | (span / 2) * tand(pitch) | 2 out rise | Total rise | ft | (span / 2) * tand(pitch) | 2 out angle | Plumb cut angle | ° | 90 - pitch | 1
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.
More in this bed
- Tile Options for Kitchen: Materials, Costs & Installation Tips
- Tile work in kitchen
- Why Are Kitchen Floors Checkerboard Tiles
- Tiles 10x10cm for Kitchen: Are They Suitable?
- Tiled Outdoor Kitchen Countertop: Pros, Cons & Installation
- Outdoor tiles Home Depot prices and buying guide