What does this calculator do?
One tool for the volume of the six most common solids: cube, rectangular prism (box), right cylinder, right cone, sphere and right square pyramid. Pick the shape, enter the dimensions it asks for, and the calculator applies the matching formula with the substitution shown. Use any length unit — the volume comes out in that unit cubed (centimetres give cm³, which divides by 1000 into litres).
Formula
One formula per shape:
Cube: V = a³ Prism: V = l × w × h Cylinder: V = πr²h Cone: V = ⅓πr²h Sphere: V = (4/3)πr³ Square pyramid: V = ⅓a²h
How to use it
Choose the shape first — the input fields adapt. Enter every dimension in the same unit. To convert the result between m³, ft³, litres or gallons, use the Volume Converter linked below.
Worked example
Cube with edge 3: V = 27. Switching to sphere with r = 3 gives V = (4/3)π × 27 = 113.0973; a cone with r = 3, h = 4 gives V = 37.6991.
Frequently asked questions
Why do the cone and pyramid formulas have the ⅓ factor?
Any solid that tapers linearly from a base to a point holds exactly one third of the prism or cylinder with the same base and height — a classical geometry result.
How do I go from cm³ to litres?
Divide by 1000 (1 L = 1000 cm³ = 1 dm³). Enter dimensions in decimetres and the result is already in litres; the Volume Converter handles other units.
Which shape approximates my container best?
Match the closest ideal solid: cans and pipes → cylinder, boxes → prism, balls → sphere, funnels → cone. Real containers with rounded corners hold slightly less than the ideal formula suggests.
Sources
- Standard solid geometry (volume, surface area, diagonals and slant heights of cubes, rectangular prisms, cylinders, cones, spheres and right square pyramids). Results are mathematically calculated from the supplied values, subject to input and display precision; π is used at full floating-point precision internally.
- OpenStax — Contemporary Mathematics (chapter on volume and surface area)
- Khan Academy — Volume and surface area (accessible explainer, not the primary source)
- Reviewed: 2026-07-31
Related calculators
Last updated: 2026-07-31 · v1.0.0 · Report an error