Trapezoid Calculator

Area, perimeter, height, midsegment, all four angles, and both diagonals — for any scalene, isosceles or right trapezoid.

Material / cost estimator

Enter a price per square metre (paint, flooring, land, fabric, etc.) to estimate the total cost from the computed area.

Enter a price and calculate an area to see the total.

What is a trapezoid?

A trapezoid is a four-sided polygon (quadrilateral) with at least one pair of parallel sides, called the bases. The other two sides are the legs, and the perpendicular distance between the two bases is the height.

Three common variants appear in practice: a scalene trapezoid has legs of different length; an isosceles trapezoid has legs of equal length and matching base angles; a right trapezoid has two 90° angles on the same leg. You'll meet them in drainage channels, retaining walls, roof trusses, bridge girders, land plots with two parallel boundaries, and the trapezoidal rule for numerical integration.

Trapezoid, case by case

Area of a trapezoid

Add the two parallel bases, halve them (the midsegment), then multiply by the perpendicular height. It's the same as making a rectangle whose length is the average of the two bases.

A = ½ (a + b) · h
a, bthe two parallel bases·hperpendicular height between bases
hABCDabcd
Example
Given
a = 6
b = 10
h = 4
Substitute
A = ½ (6 + 10) × 4
= ½ × 16 × 4
Answer
A = 32 square units

Height from the four sides

When you know both bases and both legs but not the height, drop a perpendicular from the shorter base. The horizontal offset x from the longer base gives h via the Pythagorean theorem.

x = [(b − a)² + c² − d²] / [2(b − a)]
h = √(c² − x²)
atop base·bbottom base·c, dleft and right legs
hABCDabcd
Example
Given
a = 6
b = 10
c = 5
d = 5
Substitute
x = [(10 − 6)² + 5² − 5²] / [2 × 4]
= 16/8
= 2
Answer
h = √(25 − 4)
= √21 ≈ 4.583

Midsegment (median)

The midsegment joins the midpoints of the two legs. It is parallel to both bases and equals their average — the same quantity that appears in the area formula.

m = (a + b) / 2
mmidsegment length
mABCDabcd
Example
Given
a = 6
b = 10
Substitute
m = (6 + 10) / 2
Answer
m = 8

Co-interior angle rule

Because the two bases are parallel, each pair of angles on the same leg sums to 180°. Knowing one angle at either end of a leg immediately gives you the other.

∠A + ∠B = 180°
∠C + ∠D = 180°
∠A, ∠B, ∠C, ∠Dinterior angles at vertices
ABCDabcd
Example
Given
∠A = 70°
Substitute
∠B = 180° − 70°
Answer
∠B = 110°

Full solve from a leg + base angle

Given both bases, one leg, and the base angle at that leg's foot, you can recover the height and the remaining leg. Drop a perpendicular from the top base and use right-triangle trigonometry.

h = c · sin(A)
x = c · cos(A)
d = √(h² + (b − a − x)²)
cknown leg (AB)·Abase angle at vertex A·xhorizontal offset of the top base
hABCDabcd
Example
Given
a = 6
b = 10
c = 5, ∠A
= 70°
Substitute
h = 5 · sin 70° ≈ 4.698
x = 5 · cos 70° ≈ 1.710
Answer
d ≈ √(4.698² + 2.290²) ≈ 5.227

Full solve from both base angles

With both bases and both angles at the longer base, the two legs and the height follow from the horizontal split of the trapezoid into a rectangle flanked by two right triangles.

h = (b − a) / (cot A + cot D)
c = h / sin A
d = h / sin D
A, Dbase angles at the longer base·c, dleft and right legs
hABCDabcd
Example
Given
a = 6
b = 10, ∠A
= 70°, ∠D
= 60°
Substitute
h = 4 / (cot 70° + cot 60°) ≈ 4 / (0.364 + 0.577)
Answer
h ≈ 4.251
c ≈ 4.523
d ≈ 4.908

Isosceles quick mode

An isosceles trapezoid has equal legs (c = d) and equal base angles. Give both bases and one leg and everything else — height, diagonals, area — is determined.

x = (b − a) / 2
h = √(c² − x²)
c = dthe two equal legs·xhorizontal offset at each base
hABCDabcd
Example
Given
a = 6
b = 10
c = 5 (so d
= 5)
Substitute
x = (10 − 6) / 2
= 2
h = √(25 − 4)
Answer
h = √21 ≈ 4.583

Right quick mode

A right trapezoid has two adjacent right angles on one leg. That leg is the height, and the remaining slanted leg is found from the base difference by the Pythagorean theorem.

h = c
d = √(h² + (b − a)²)
cthe perpendicular leg (= height)·dthe slanted leg
hABCDabcd
Example
Given
a = 6
b = 10
c = 4
Substitute
h = 4
d = √(4² + 4²)
= √32
Answer
d ≈ 5.657

Formulas at a glance

Area A = ½ (a + b) · h
Perimeter P = a + b + c + d
Midsegment m = (a + b) / 2
Height from a leg h = c · sin(∠A)
= d · sin(∠D)
Co-interior pairs ∠A + ∠B = 180°, ∠C + ∠D
= 180°
Height from 4 sides x = [(b − a)² + c² − d²] / [2(b − a)]
h = √(c² − x²)
Area from diagonals A = ½ · p · q · sin θ

All formulas — every calculation mode

The exact symbolic chain each mode of this calculator evaluates. Same notation as the widget: a, b are the parallel bases, c, d the legs, h the height, m the midsegment, P the perimeter, A the area, and x the horizontal offset of the top base from the bottom-left corner.

1. Find Area — given a, b, h
A = ½ (a + b) · h
m = (a + b) / 2
2. Find a — given A, b, h
a = 2A / h − b
m = (a + b) / 2
3. Find b — given A, a, h
b = 2A / h − a
m = (a + b) / 2
4. Find h — given A, a, b
h = 2A / (a + b)
m = (a + b) / 2
5. Full solve — given a, b, c, ∠A
h = c · sin(∠A)
x = c · cos(∠A)
d = √((b − x − a)² + h²)
∠D = atan2(h
b − x − a)
∠B = 180° − ∠A, ∠C
= 180° − ∠D
A = ½(a + b)h
P = a + b + c + d
m = (a + b)/2
6. Full solve — given a, b, d, ∠D
h = d · sin(∠D)
x = b − a − d · cos(∠D)
c = √(x² + h²)
∠A = atan2(h
x)
∠C = 180° − ∠D, ∠B
= 180° − ∠A
A = ½(a + b)h
P = a + b + c + d
m = (a + b)/2
7. Full solve — given a, b, ∠A, ∠D
h = (b − a) / (cot ∠A + cot ∠D)
c = h / sin(∠A)
d = h / sin(∠D)
∠B = 180° − ∠A, ∠C
= 180° − ∠D
A = ½(a + b)h
P = a + b + c + d
m = (a + b)/2
8. Full solve — given all 4 sides a, b, c, d
x = [(b − a)² + c² − d²] / [2(b − a)]
h = √(c² − x²)
m = (a + b)/2
P = a + b + c + d
A = ½(a + b)h
9. Isosceles quick — given a, b, c (legs equal)
x = (b − a)/2
h = √(c² − x²)
∠A = ∠D, ∠B
= ∠C
A = ½(a + b)h
10. Right quick — given a, b, c (vertical leg)
h = c
d = √((b − a)² + c²)
∠A = ∠B
= 90°
A = ½(a + b)h
11. Area — given diagonals p, q and angle θ
A = ½ · p · q · sin θ
12. From 4 vertex coordinates (shoelace)
A = ½ |Σ (xᵢ yᵢ₊₁ − xᵢ₊₁ yᵢ)|
h = 2A / (base₁ + base₂)
m = (base₁ + base₂) / 2

What this tool does for you

  • Twelve calculation modes — from a simple A = ½(a+b)h to a full solve from 4 vertex coordinates
  • Scalene, isosceles and right diagrams with vertex, side, angle and height labels
  • Reports area, perimeter, height, midsegment, all four interior angles and both diagonals
  • Unit selector (mm, cm, m, km, in, ft, yd) with automatic m² conversion for the cost estimator
  • Show/hide step-by-step working for every mode
  • Material or cost estimator — enter a price per m² and get the total

Frequently asked questions

+What's the difference between a trapezoid and a trapezium?
Regional terminology. In US English a trapezoid is a quadrilateral with exactly one pair of parallel sides. In UK English the same shape is a trapezium, while trapezoid means a quadrilateral with no parallel sides. This calculator uses the US convention.
+What makes a trapezoid isosceles?
An isosceles trapezoid has legs of equal length (c = d). As a consequence, the base angles are equal in pairs (∠A = ∠D, ∠B = ∠C), the diagonals are equal (p = q), and the shape has a line of symmetry perpendicular to the bases through their midpoints.
+When should I use the Isosceles or Right quick modes?
Pick these when you already know the shape is symmetric or has a perpendicular leg. The Isosceles quick mode takes just the two bases and one leg length (both legs equal), and derives the height, second leg and all four angles automatically. The Right quick mode treats the entered leg c as the vertical side (so ∠A = ∠B = 90° and h = c), then computes the slanted leg d and the remaining angles. Selecting "Isosceles" or "Right" from the Trapezoid type dropdown switches you into the matching quick mode automatically.
+How do the diagonals relate to the area?
For any quadrilateral, A = ½ · p · q · sin θ, where θ is the angle between the diagonals. This is why the "diagonals + angle" mode works without knowing the bases. If you only know p, q and the height h, the area isn't uniquely determined — you still need one base or the angle between the diagonals.
+When does a trapezoid become a parallelogram?
When both pairs of opposite sides are parallel — equivalently, when a = b. The area formula still works (½(a+a)h = a·h), which matches the parallelogram area. Under the exclusive US definition, that shape is no longer called a trapezoid; under the inclusive definition, every parallelogram is a trapezoid.
+Which mode should I pick for a real problem?
If you measured height perpendicular to the bases, use Find Area — a, b, h. If you only have the four side lengths, use all 4 sides — the height is derived. If you have field angles at the base corners, use the angles A & D mode. If you have vertex GPS or CAD coordinates, use coordinates.

Related calculators