Pyramid calculator

Calculate the volume, lateral surface area, total surface area and slant heights of square and rectangular pyramids — with a truncated pyramid option and live visual explanations.

Report error
Volume
—
⅓ × base area × height
Lateral area
—
sloping faces only
Total surface
—
lateral + base(s)

Live pyramid geometry

The construction follows the current base and height

LIVE
Height —Base area —

Volume as height changes

With the current base fixed, volume grows linearly with h

LIVE
Current V —V = ⅓Bh

Lateral area vs base area

Compare the two components of total surface area

LIVE
Total surface —Lateral + base
LIVE GEOMETRY INSIGHTS

What the dimensions are telling you

Base area—a × b
Volume factor⅓of matching prism
Height / base—h ÷ √B
Surface / volume—total area ÷ volume
Change the dimensions to see the geometry update live.

Calculated properties

LIVE
PropertyValue
V = ⅓ × B × h
THE CONCEPT

What is a pyramid?

A pyramid is a solid with a polygonal base and a single apex connected to the base by triangular faces. The perpendicular height h is measured straight from the apex to the base plane; it is not the same thing as the slant height of a face.

h base area B slant face apex
The dashed segment is the perpendicular height. A face's slant height ℓ follows a different right triangle.

Volume

V = ⅓Bh

Take the base area B, multiply by the perpendicular height h, then divide by 3.

Surface area

S = B + L

Total surface combines the base area with the lateral area of the triangular faces.

Key distinction: the perpendicular height h goes to the base plane. The slant height ℓ runs along a triangular face. Using h in a lateral-area formula is a common source of error.

Why the factor 1/3 matters

For any pyramid, the volume is one-third of a prism with the same base area and perpendicular height. That is why V = (1/3)Bh works even when the base is not a square. This general relationship is also the reason pyramid volume parallels the one-third factor used for a cone.

THE FORMULAS

Pyramid formulas, step by step

The volume formula needs only base area and perpendicular height. Surface-area formulas need the geometry of the sloping faces, so the slant height must be derived first.

V = ⅓Bh
V
pyramid volume
B
area of the base
h
perpendicular height

Rectangular base

B = ab

For base length a and width b.

Square base

B = s²

A square is the special case where a = b = s.

Slant height of a rectangular pyramid

For a right rectangular pyramid, there are generally two face slant heights. Across the faces whose base edge is a, the triangular-face height is based on half of b; across faces whose base edge is b, it is based on half of a.

ℓₐ = √(h² + (b/2)²)     ℓᵦ = √(h² + (a/2)²)
L = aℓₐ + bℓᵦ
L
lateral surface area of the four triangular faces
a,b
base side lengths
ℓₐ,ℓᵦ
corresponding face slant heights
S = L + B = aℓₐ + bℓᵦ + ab

Truncated pyramid (frustum)

If the apex is cut parallel to the base, the result is a frustum. With bottom dimensions a × b, top dimensions a′ × b′ and height h, the volume uses the geometric-mean relationship between the two rectangular base areas.

V = h/3 × (B₁ + √(B₁B₂) + B₂)
B₁ = ab    B₂ = a′b′
For a square frustum with bottom side a and top side b, this reduces to V = h/3 × (a² + ab + b²). This is the square-frustum relationship used for the square-frustum special case.
WORKED EXAMPLES

Pyramid examples with full reasoning

Example 1 — Square pyramid volume

Suppose a square pyramid has side length s = 6 m and perpendicular height h = 4 m. Its base area is 6² = 36 m².

V = ⅓ × 36 × 4 = 48 m³

Example 2 — Slant height and surface area

For the same square pyramid, the face slant height is the hypotenuse of a right triangle with legs h = 4 and s/2 = 3.

ℓ = √(4² + 3²) = 5 m
L = 2sℓ = 2 × 6 × 5 = 60 m²
S = 36 + 60 = 96 m²

Example 3 — Rectangular pyramid

Take a = 8 m, b = 5 m and h = 9 m. The base area is 40 m², so the volume is:

V = ⅓ × 40 × 9 = 120 m³

Example 4 — Truncated square pyramid

Let the bottom side be 6 m, the top side 2 m and the perpendicular height 4 m. The square-frustum formula gives:

V = 4/3 × (36 + 12 + 4) = 69.333… m³
Sanity check: when the top side of a square frustum approaches zero, it becomes a full square pyramid. The frustum volume then reduces to the ordinary ⅓s²h formula.
REAL-WORLD GEOMETRY

Where pyramid calculations are useful

Architecture

Pyramidal roofs, monuments, skylights and tapered structural elements use the same base-area, height and slant relationships.

Packaging

Pyramid-shaped packages and displays use volume for capacity and lateral area for material estimates.

Construction

Surface area helps estimate cladding, paint, membrane or sheet material on sloping faces.

Education

The pyramid is an excellent model for connecting area, volume, Pythagorean theorem and three-dimensional reasoning.

FAQ

Pyramid calculator questions

How do you calculate the volume of a pyramid?

Find the base area B, multiply it by the perpendicular height h, then divide by 3: V = ⅓Bh.

What is the difference between height and slant height?

The perpendicular height goes from the apex to the base plane at 90°. The slant height runs along a triangular face. They are different lengths except in special limiting situations.

What is the surface area of a rectangular pyramid?

For a right rectangular pyramid, calculate the two corresponding face slant heights, then use L = aℓₐ + bℓᵦ and add the base area ab for total surface area.

Does the volume formula work for an oblique pyramid?

Yes. The general pyramid volume relationship still uses one-third of base area times perpendicular height. The slant/surface geometry becomes different when the apex is not above the base center.

What happens when a square pyramid is cut at the top?

You get a square pyramid frustum. Its volume depends on the bottom area, top area and the geometric-mean term between them.

What are the units of pyramid volume and surface area?

If lengths are measured in meters, area is in m² and volume is in m³. The calculator preserves the mathematical units implied by your input dimensions.