Volume Calculator

Pick a shape and enter its measurements to get the volume in cubic units, liters, gallons and more.

Volume
–
In other units

    Calculated in your browser. Nothing you enter is sent anywhere.

    How to use the volume calculator

    Choose a shape, then type its measurements in one length unit. The result shows the volume in that unit cubed, and you can switch it to liters, milliliters, cubic feet, US or UK gallons and more.

    Volume formulas

    ShapeFormula
    Boxlength × width × height
    Cubeside³
    Cylinderπ × r² × h
    Sphere4⁄3 × π × r³
    Hemisphere2⁄3 × π × r³
    Cone1⁄3 × π × r² × h
    Pyramid (rectangular base)1⁄3 × length × width × height
    Triangular prism½ × base × triangle height × length
    Capsuleπ × r² × h + 4⁄3 × π × r³ (h = straight part only)

    Examples

    • Aquarium: 100 cm × 40 cm × 50 cm = 200,000 cm³ = 200 liters, about 52.8 US gallons.
    • Concrete slab: 4 m × 3 m × 0.1 m = 1.2 m³. Order a little extra, around 5 to 10%.
    • Ball: a basketball with a radius of 12 cm holds 4⁄3 × π × 1,728 ≈ 7,238 cm³, about 7.2 liters.
    • Raised garden bed: 8 ft × 4 ft × 1 ft = 32 ft³, about 1.19 cubic yards of soil.

    Tips

    • Use the radius (half the width), not the diameter, for round shapes.
    • Measure the inside of a container if you want to know how much it holds.
    • Volume units are cubed: 1 m is 100 cm, but 1 m³ is 1,000,000 cm³.

    Frequently asked questions

    How do I calculate the volume of a box?

    Multiply length × width × height. A box 40 cm × 30 cm × 20 cm holds 24,000 cm³, which is 24 liters.

    How many liters are in a cubic meter?

    Exactly 1,000 liters. A liter is the same as 1,000 cm³ (a cube 10 cm on each side), and 1 mL is 1 cm³.

    How many gallons are in a cubic foot?

    About 7.48 US gallons, or about 6.23 UK (imperial) gallons. A US gallon is 3.785 liters and a UK gallon is 4.546 liters, so always check which one you need.

    How do I find the volume of a cylinder?

    Multiply π × radius² × height. A round tank 1 m across (radius 0.5 m) and 1.5 m tall holds π × 0.25 × 1.5 ≈ 1.178 m³, about 1,178 liters.

    Why is a cone one third of a cylinder?

    A cone with the same base and height as a cylinder holds exactly one third as much. The same is true of a pyramid and a box. This was first proved by Eudoxus and Archimedes.

    Exact unit definitions from NIST Handbook 44, Appendix C (1 in = 2.54 cm, 1 US gallon = 231 in³ = 3.785411784 L, 1 UK gallon = 4.54609 L). Formulas checked in our tests against hand-worked examples.

    Last reviewed: . Results are estimates for information only.