Right triangle calculator
Pick which two values you know. Side a is the rise (vertical), side b the run (horizontal), c the sloping side and the angle is measured at the bottom between b and c.
How it works
Pythagoras: c² = a² + b², so c = √(a² + b²), a = √(c² - b²) and b = √(c² - a²).
With an angle: a = c x sin(angle), b = c x cos(angle), a = b x tan(angle). The angle itself is atan(a / b).
The 3-4-5 rule is a quick check for a square corner: measure 3 m along one side, 4 m along the other, and the diagonal must be exactly 5 m.
Results are estimates for planning. Check product data sheets, local building rules and an engineer's calculations where required.
Frequently asked questions
How do I find the rafter length?
Use half the span as the run (b) and the roof pitch as the angle. The hypotenuse c is the rafter length to the wall line, before overhang and plumb cuts.
How do I check that a corner is square?
Measure a and b along the two sides and compare the diagonal with c from this calculator. Any difference means the corner is out of square.
More tools in everyday helpers
🫧Spirit level appTurn your phone into a bubble level.🔁Unit converterConvert any common building unit in one place: mm to inches, m² to square feet, bar to psi, kW to BTU/h and more.⭕Circle and arc calculatorGet circumference and area of a circle, or use arc mode to set out an arch, a curved wall or a round bed from its width and height.⬛Area calculatorChoose the shape, enter the measurements in metres and get the area in m², plus the amount to order with waste.🔩Steel weight calculatorPick the profile and material, enter the dimensions in mm and the length, and get the weight for ordering, lifting or transport.📏Inch fraction to mm converterConvert between millimetres and inch fractions such as 3/8" or 1 1/4".
All tools (64) →