Skip to main content
ilovecalcs logoilovecalcs.

Math · Live

Volume, for any 3D shape.

Solve for the volume of a sphere, cube, cylinder, cone, capsule, or rectangular tank. Switch shapes with one tap, and read the result in cubic meters, liters, and US gallons at the same time.

FormulasReal-time

Inputs

Pick a shape

m

Distance from center to surface

Formula

V = (4 ⁄ 3) · π · r³

Volume · Sphere

Real-time
4.1888
Cubic meters
4.1888
Liters
4,188.79L
US Gallons
1,106.56gal
Cubic feet
147.926ft³
Cubic cm
4,188,790cm³

Step by step

How we got there

Sphere
  1. 1

    Plug the radius into V = (4/3)·π·r³

    (4 ⁄ 3) × π × (1 m)³

  2. 2

    Cube the radius, then scale

    (4 ⁄ 3) × 3.14159… × 1 = 4.1888 m³

  3. 3

    Convert to other units

    4.1888 m³ = 4188.79 L = 1106.56 gal

Quick compare

Each shape with your dimensions

m
ShapeLitersUS gal
Sphere4.18884,188.791,106.56
Cube11,000264.17
Cylinder6.28326,283.191,659.84
Cone2.09442,094.4553.28
Capsule10.47210,471.982,766.4
Rectangular Tank22,000528.34

Field guide

What volume actually measures.

Volume is how much three-dimensional space an object occupies. For a hollow shape, a tank, a flask, a fuel cell, it's also exactly how much fluid the object can hold. Every formula below gives the answer in cubic units: cubic meters, cubic feet, cubic inches. Liters and gallons are just the same number in a different costume: 1 m³ = 1,000 L = 264.172 US gal.

Sphere: V = (4 ⁄ 3) · π · r³

A sphere is defined by a single number: its radius. The volume scales with the cube of that radius, which is why doubling a beach ball's diameter makes it eight times larger inside, not twice.

V = (4 ⁄ 3) · π · r³

Cube: V = a³

The simplest of all volume formulas. A cube has six identical square faces, so its volume is its edge length a multiplied by itself three times.

V = a³

Cylinder: V = π · r² · h

A cylinder is a stack of identical circles. The area of one circle is π · r²; multiplying by the height h stretches that area through space. This is the formula behind cans, pipes, hot-water tanks, and engine displacement.

V = π · r² · h

Cone: V = (1 ⁄ 3) · π · r² · h

A cone with the same radius and height as a cylinder holds exactly one-third the volume, a handy mental check the next time you're scooping ice cream. Use the perpendicular height (apex straight down to the base centre), not the slant.

V = (1 ⁄ 3) · π · r² · h

Capsule: V = π · r² · h + (4 ⁄ 3) · π · r³

A capsule is a cylinder of length h with a hemispherical cap at each end. Add the cylinder formula to a full sphere's formula (the two hemispheres make one whole sphere) and you're done. Pharmaceutical capsules, propane tanks, and submarine hulls are all capsule-shaped.

V = π · r² · h + (4 ⁄ 3) · π · r³

Heads-up: the h here is thestraight-side length only. The total length of the capsule is h + 2r.

Rectangular Tank: V = l · w · h

Length × width × height. The formula behind shipping containers, swimming pools, fish tanks, and almost every box-shaped storage problem in the world.

V = l · w · h

From cubic units to liters and gallons

Once you have a volume in any cubic unit, switching to liters or gallons is a single multiplication. The conversions baked into this calculator:

  • 1 m³ = 1,000 L
  • 1 m³ ≈ 264.172 US gallons
  • 1 m³ ≈ 35.315 ft³
  • 1 m³ = 1,000,000 cm³
  • 1 ft³ ≈ 7.481 US gallons

Heads up: US gallons and UK (imperial) gallons are not the same; an imperial gallon is about 20% larger. This calculator uses US gallons by default since most volume-related queries on the open web do.

Tips for getting an accurate answer

  • Match your units. If you measured in centimeters, set the unit picker to cm before entering. Mixing inches with meters is the #1 way these calculators give wildly wrong answers.
  • Use the perpendicular height. For cones and cylinders, height means the straight-down distance from the apex (or top circle) to the base, not the slant length on the outside.
  • Inside dimensions for capacity, outside for displacement. A 10 mm-thick steel tank with a 1 m outside radius has only ~0.99 m of usable interior radius for capacity calculations.
  • Round at the end. Round each input measurement first and the small errors compound. Enter the raw measurement and round the final answer.

Worked example: how big is a 12 oz soda can?

A standard US soda can is about 6.6 cm in diameter and 12.2 cm tall. That's a cylinder with r = 3.3 cm and h = 12.2 cm:

V = π × (3.3)² × 12.2 ≈ 417 cm³ ≈ 0.417 L ≈ 14.1 US fl oz

The 12 oz of liquid leaves a small headspace at the top of the can, roughly 2 fl oz of CO₂-rich air, which is why the can sounds hollow when you tap it.