Skip to content
Back to Calculators

Volume Calculator for 3D Shapes

Volume of a sphere, cylinder, cone, box, capsule, cap, frustum, ellipsoid, pyramid or tube, with mixed units and tank capacity

rh

V = πr²h

Each length can use its own unit. Calculated in your browser; nothing you enter is saved or sent.

Illustrative example shown for this shape. Enter your own dimensions and press Calculate.

Volume
37.69911184 m³
exactly 12π in cubed units
Full capacity
37,699.11184 L
37,699,111.84 mL
US gallons
9,959.051748 gal
liquid gallons, 231 in³ each
The same volume in eight units
UnitVolume
cubic metres (m³)37.69911184
cubic centimetres (cm³)37,699,111.84
cubic feet (ft³)1,331.33157
cubic inches (in³)2,300,540.954
cubic yards (yd³)49.30857668
litres (L)37,699.11184
millilitres (mL)37,699,111.84
US gallons (gal)9,959.051748
How the volume changes when every length is scaled
Every length × …0.5123
Volume is × …0.1251827
Volume (m³)4.7123889837.69911184301.59289471,017.87602

The steps

  1. Cylinder: V = πr²h.
  2. π × 2² × 3 = 12π ≈ 37.69911184 m³.

Units, radius and diameter

Volume is the amount of space a solid takes up, measured in cubic units: cubic metres, cubic feet, cubic inches and so on. Every length you enter must be measured in a unit, and each field on this page has its own unit menu, so you can mix centimetres and metres or inches and feet without converting anything yourself. The calculator converts every length to metres first, applies the formula, and then reports the answer in eight units, including litres and US gallons.

Many shapes are defined by a radius, the distance from the centre to the edge. If you measured across the full width instead, tick the diameter option and the calculator halves it for you. This matters more than it looks: a sphere with radius 6 m holds 904.7786842 m³, but entering 6 as a diameter means a radius of 3 and gives 113.0973355 m³, an eighth as much. Where a result involves π, you also see the exact form, such as 12π for the cylinder below, as long as all lengths use the same unit.

Sphere

A sphere is perfectly round: every point on its surface is the same distance, r, from the centre. Its volume is V = 4πr³ ÷ 3. Because the radius is cubed, small changes matter a lot. Double the radius and the volume grows by a factor of 8.

Worked example: a ball of radius 3 m has V = 4 × π × 3³ ÷ 3 = 36π ≈ 113.0973355 m³, or 113,097.3355 litres. Use the radius, not the diameter, unless you tick the diameter box. The same formula covers a water balloon, a ball bearing or a planet; only the unit changes.

Cone

A cone has a circular base of radius r and tapers to a point at height h. Its volume is V = πr²h ÷ 3, exactly one third of the cylinder with the same base and height. The height here is the straight-up distance from the base to the tip, not the slanted length along the side.

Worked example: a cone with base radius 3 cm and height 4 cm has V = π × 3² × 4 ÷ 3 = 12π ≈ 37.69911184 cm³. Traffic cones, funnels and piles of sand or gravel are all roughly conical, which makes this one of the most useful formulas for estimating loose material.

Cube

A cube has six equal square faces, so a single edge length a describes it. The volume is V = a³, the edge multiplied by itself three times. Doubling the edge multiplies the volume by 8, just as with a sphere.

Worked example: a cube with 10 cm edges has V = 10³ = 1000 cm³, which is exactly 1 litre. That is the definition of the litre: a cube 10 cm on each side. This is a handy cross-check for any unit conversion you do by hand, and it is why 1 m³ equals 1,000 litres.

Cylinder

A cylinder has two parallel circular ends of radius r joined by a straight side of height h. Its volume is V = πr²h: the area of the circular base multiplied by the height. The same formula works for a pipe, a drum, a silo or a round column, whichever way it lies.

Worked example: a cylinder with radius 2 m and height 3 m has V = π × 2² × 3 = 12π ≈ 37.69911184 m³. For a tank you would fill, such as radius 0.5 m and length 1.2 m, the full capacity is 942.4777961 litres, about 248.9762937 US gallons.

Rectangular box, tank or prism

A rectangular box, also called a rectangular prism or cuboid, has three independent measurements: length l, width w and height h. The volume is V = l × w × h. A flat rectangle has only an area, l × w; give it a third dimension of depth and it becomes a box with a volume.

Worked example: a box 2 m long, 3 m wide and 4 m high has V = 2 × 3 × 4 = 24 m³. A pool 4 m long, 2 m wide and 1.5 m deep holds 12 m³, which is 12,000 litres when full. For concrete or gravel orders in cubic yards, the <a href="/calculators/concrete">concrete calculator</a> does the unit work for you.

Capsule

A capsule is a cylinder with a hemisphere on each end. It is described by the radius r and the barrel height h, the straight section between the two hemispheres. The volume is V = πr²h + 4πr³ ÷ 3: the cylinder plus one whole sphere, because the two hemispheres join to make one.

Worked example: radius 1 m and barrel height 2 m gives V = π × 1² × 2 + 4 × π × 1³ ÷ 3 = 10π/3 ≈ 10.47197551 m³. Remember that the overall length of a capsule is the barrel plus two radii, here 2 + 2 = 4 m, so do not enter the full length as h.

Spherical cap

A spherical cap is the piece of a sphere cut off by a flat plane, like a dome. Three lengths describe it: the sphere radius R, the cap height h and the base radius r, linked by r² = h(2R − h). Give any two and the calculator finds the third. The volume is V = πh²(3R − h) ÷ 3.

Worked example: with R = 2 m and h = 2 m the cap is a hemisphere, and V = π × 2² × (3 × 2 − 2) ÷ 3 = 16π/3 ≈ 16.75516082 m³. If you give r and R only, two caps fit, a smaller and a larger one, and the calculator shows both volumes.

Conical frustum

A conical frustum is a cone with its tip cut off by a plane parallel to the base, like a bucket or a lampshade. It has a top radius r, a bottom radius R and a height h. The volume is V = πh(r² + rR + R²) ÷ 3. If r is 0 the frustum is a full cone, and if r equals R it is a cylinder.

Worked example: top radius 1 m, bottom radius 2 m, height 3 m gives V = π × 3 × (1 + 2 + 4) ÷ 3 = 7π ≈ 21.99114858 m³. Measure the radii across the circles, not along the slanted side.

Ellipsoid

An ellipsoid is a stretched or squashed sphere, with three semi-axes a, b and c, each measured from the centre to the surface along one direction. The volume is V = 4πabc ÷ 3. When all three are equal it is a sphere, and the formula reduces to 4πr³ ÷ 3.

Worked example: semi-axes 1 m, 2 m and 3 m give V = 4 × π × 1 × 2 × 3 ÷ 3 = 8π ≈ 25.13274123 m³. An egg, a rugby ball and an oil-storage tank with curved ends are approximately ellipsoidal. Remember that semi-axes are half the full width in each direction.

Square pyramid

A square pyramid has a square base with edge a and rises to a single point at height h above the base. The volume is V = a²h ÷ 3, one third of the box with the same base and height. As with a cone, h is the vertical height, not the slanted face.

Worked example: a base edge of 4 m and a height of 3 m gives V = 4² × 3 ÷ 3 = 16 m³. Roofs, tents and stockpiles are often pyramid-shaped; the one-third rule is the quick sanity check.

Tube or hollow cylinder

A tube is a cylinder with a cylindrical hole through it: a pipe wall, a bushing or a ring. It has an outer diameter D, an inner diameter d and a length h. The volume of the material is V = π(D² − d²)h ÷ 4, the big cylinder minus the hole. The calculator checks that the inner diameter is smaller than the outer one.

Worked example: D = 4 m, d = 2 m and h = 2 m gives V = π × (4² − 2²) × 2 ÷ 4 = 6π ≈ 18.84955592 m³. This is the volume of the wall; to find what a pipe holds, use its inner diameter in the cylinder formula instead.

Full tank capacity versus fill level

For the shapes that can act as containers (cube, cylinder, box, capsule, frustum and tube), the page shows the full capacity in litres and US gallons. Capacity uses the internal dimensions, because liquid sits inside the walls. If you measure a tank from outside, subtract the wall thickness on every side first. This page gives the capacity when the container is full; the volume of a part-filled tank depends on the depth of the liquid and is a separate calculation.

Frequently asked questions

How do I convert cubic metres to litres?

Multiply by 1,000. One cubic metre is 1,000 litres, and one litre is 1,000 cubic centimetres.

Does doubling the radius double the volume of a sphere?

No, it multiplies it by 8, because the radius is cubed.

Should I use the outer dimensions of a tank?

No. For capacity use the internal dimensions, since the walls take up space that cannot hold liquid.

Is a cone's height the slant height?

No. Use the vertical height from the base to the tip, which is shorter than the slant.

What is the length of a capsule?

The overall length is the barrel height plus two radii. This calculator asks for the barrel height.

For materials, try the gravel calculator and the mulch calculator, or browse all calculators.

Get New Free Calculators by Email

Get practical calculator walkthroughs and new tool updates by email. Occasional emails only, unsubscribe at any time.

No spam. See our privacy policy.