How to use the volume calculator
- Pick the shape from the first list. The input boxes change to match: a cube needs one side, a box needs width, length and height, and a cylinder needs a radius and a height.
- Choose the length unit you measured in. Millimeters, centimeters, meters, inches and feet are supported, and the result is shown in that unit cubed as well as in standard volume units.
- Type each measurement. Use a period for decimals. If you measured across a round object, divide the diameter by two before typing it as the radius.
- Press Calculate volume. The top line shows the volume, and the rows below convert it to cubic meters, liters, US gallons and cubic centimeters and add the total surface area.
- Copy the summary with one click, or press Clear to start a new shape.
Volume formulas for each shape
Volume measures how much three-dimensional space an object occupies, or how much a container can hold. Every formula in this tool is the standard textbook one, so you can check the answer by hand.
- Cube: V = a³, where a is the side length. A cube with 4 inch sides holds 64 cubic inches.
- Rectangular box: V = width × length × height. A moving box measuring 18 × 18 × 24 inches holds 7,776 cubic inches, or about 4.5 cubic feet.
- Cylinder: V = π × r² × h. This is the formula for cans, pipes, drums, round tanks and columns.
- Cone: V = π × r² × h ÷ 3, exactly one third of the cylinder with the same base and height.
- Sphere: V = 4/3 × π × r³. Balls, spherical tanks and domes (half a sphere) use it.
- Square pyramid: V = a² × h ÷ 3, again one third of the box with the same base and height.
The tool also reports the total surface area, which is useful when you need paint, insulation, wrapping or sheet material. For the cone and pyramid it uses the slant height calculated from the radius or base and the vertical height.
From cubic units to liters and gallons
Once you have a volume in cubic centimeters, one liter is exactly 1,000 cm³, and one cubic meter is 1,000 liters. In the United States one gallon is 231 cubic inches, or about 3.785 liters. One cubic foot of water is about 7.48 US gallons and weighs roughly 62.4 pounds. Because these relationships come up constantly, the calculator lists liters and US gallons next to the cubic units rather than making you convert by hand. Note that the imperial (UK) gallon is larger, about 4.546 liters, so if a UK product label says gallons, the figure will not match the US gallon result shown here.
The same idea works backwards. If you know you need a 200 liter tank, you can try a cylinder with different radius and height values until the liter row matches your target. This is a quick way to compare a tall narrow tank with a short wide one that holds the same amount.
Practical examples
Water barrel: a barrel with a 12 inch radius and a 35 inch height has a volume of about 15,834 cubic inches, which is roughly 68.5 US gallons. Round planter: a pot with a 10 inch radius filled to a depth of 12 inches needs about 3,770 cubic inches of soil, a little over 2.18 cubic feet. Shipping box: a box measuring 30 × 20 × 15 centimeters holds 9,000 cm³, or 9 liters. Ice cream cone: a cone with a 3 centimeter radius and a 10 centimeter height holds about 94.2 cm³, which is less than a tenth of a liter.
Students use the same results to check homework. Enter the numbers from a geometry problem, compare with your own working, and read the surface area row as a bonus check for questions that ask for both quantities.
Tips for accurate results
- Measure inside dimensions if you want the capacity of a container, and outside dimensions if you want the space it takes up on a shelf or truck.
- Use one unit for everything. The tool applies the unit you choose to every field, so do not mix inches for one value and centimeters for another.
- Keep full precision while measuring and let the calculator round at the end. Rounding the radius first can noticeably change a cubed or squared result.
- For a partly filled horizontal tank or an irregular shape, split it into simple shapes, calculate each one, and add the volumes together.
- For a hollow object such as a pipe, calculate the outer cylinder and the inner cylinder separately and subtract.
Accuracy and limits
The calculator uses double precision arithmetic and displays up to six decimal places, switching to scientific notation for extremely large or small results. It assumes perfect geometry, so real containers will differ slightly. For liquids, remember that thermal expansion and the fill line below the brim reduce the practical capacity. It does not handle shapes with curved or irregular cross sections, and it is not a substitute for engineering calculations where safety is involved.
Private by design
Every calculation happens inside your browser. The measurements you type are never uploaded, saved or tracked, and the page keeps working offline once it has loaded. That makes it safe to use for work projects, quotes and anything else you would rather not share.
Frequently asked questions
How do I calculate the volume of a cylinder?
Multiply pi by the radius squared, then by the height: V = π × r² × h. A cylinder with a 5 cm radius and a 10 cm height has a volume of about 785.4 cm³. Choose Cylinder in the tool, enter the radius and the height, and it does the work and converts the answer to liters and gallons.
Do I enter the radius or the diameter?
The radius. The radius is half of the diameter, the distance from the center to the edge. If you measured across the whole circle, divide that number by two before typing it in.
How many gallons are in a cubic foot?
One cubic foot is about 7.48 US gallons, or 28.32 liters. The calculator shows the US gallon figure automatically, so you can enter feet as the unit and read the gallons directly.
What is the difference between volume and capacity?
Volume is the space an object occupies, while capacity is how much a container can hold inside. They are the same number only if you use the inside dimensions. For a tank, measure the inside diameter and inside height to get its capacity.
How do I find the volume of a cone?
Use V = π × r² × h ÷ 3. It is exactly one third of a cylinder with the same radius and height. Select Cone and enter the base radius and the vertical height, not the slanted side.
Why does the result show scientific notation?
Extremely large or small values are easier to read as a number times a power of ten. For example 1.2346e+12 means 1,234,600,000,000. For everyday sizes the tool uses normal numbers with thousands separators.
Can I convert the answer to cubic yards or imperial gallons?
The tool lists cubic meters, liters, US gallons and cubic centimeters. For cubic yards divide cubic feet by 27, or multiply cubic meters by 1.308. For imperial gallons multiply liters by 0.22.
Are my measurements uploaded anywhere?
No. The calculation runs entirely in your browser, nothing is sent to a server, and nothing is stored or tracked.
Related tools
Need custom software, a faster website or help with digital projects? The team at 4D1A can help.