How to use the volume calculator
- Pick the shape and the unit. Choose the solid that matches your object and the unit you measured in: inches, feet, yards, or metric units.
- Enter the dimensions. Boxes need length, width and height. Round shapes need the radius, which is half the diameter. Cones, cylinders and pyramids also need the height, measured straight up from the base.
- Read the results. The large figure is the volume in cubic units. The cards show the surface area, US gallons, cubic feet, cubic yards and liters, so you can go straight to what a store or a recipe asks for.
The calculator opens on the shipping crate from OpenStax’s Prealgebra 2e: 30 × 25 × 20 inches, which holds 15,000 cubic inches (about 64.9 gallons, or 8.68 cubic feet) and has 3,700 square inches of surface.
Volume and surface area formulas
| Solid | Volume | Surface area |
|---|---|---|
| Box | L × W × H | 2LH + 2LW + 2WH |
| Cube | s³ | 6s² |
| Cylinder | πr²h | 2πr² + 2πrh |
| Sphere | (4/3)πr³ | 4πr² |
| Hemisphere | (2/3)πr³ | 3πr² (curved part plus flat base) |
| Cone | (1/3)πr²h | πr² + πr√(r² + h²) |
| Rectangular pyramid | (1/3) × L × W × H | base + four triangular faces |
| Capsule | πr²h + (4/3)πr³ | 2πrh + 4πr² |
The textbook (section 9.6) works through several of these, and the calculator matches each one:
- A rectangular solid 14 × 9 × 17 cm: volume 2,142 cm³, surface area 1,034 cm².
- A cube 2.5 inches on a side: volume 15.625 in³, surface area 37.5 in².
- A sphere with a 6-inch radius: volume 288π ≈ 904.8 in³, surface area 144π ≈ 452.4 in².
- A cylinder with a 3-inch radius and 5-inch height: volume 45π ≈ 141.4 in³, surface area 48π ≈ 150.8 in².
Textbook answers that use π ≈ 3.14 come out slightly lower, for example 904.32 instead of 904.78 for the sphere. The calculator uses π to full precision.
Why cones and pyramids are one-third
A cone holds exactly one-third of a cylinder with the same base and height, as the textbook notes, and a pyramid holds one-third of the box with the same base and height. So a cone with a 3-inch radius and 4-inch height holds 12π ≈ 37.7 cubic inches, a third of the 36π in the matching cylinder. Likewise a sphere fills two-thirds of the smallest cylinder that contains it. These ratios are useful sanity checks when an answer looks off.
Cubic feet, cubic yards and gallons
Volume units are the length unit cubed, so conversion factors are cubed too. One cubic foot is 12³ = 1,728 cubic inches, and one cubic yard is 3³ = 27 cubic feet, not 3 or 9.
A US liquid gallon is defined as 231 cubic inches, which is 3.785411784 liters. That makes one cubic foot about 7.48 gallons. NIST’s conversion tables list the gallon as 3.785412 liters and the cubic foot as 0.02831685 cubic meters.
- Aquariums and tanks: a tank 36 × 18 × 16 inches holds 10,368 cubic inches, or about 44.9 gallons, before you allow for glass thickness and substrate.
- Concrete, soil and mulch: sold by the cubic yard. A 10 × 10 foot slab 4 inches thick is 10 × 10 × (4 ÷ 12) ≈ 33.3 cubic feet, about 1.23 cubic yards. Convert the thickness to feet before multiplying.
- Pools: a round pool is a cylinder. An 18-foot pool filled 4 feet deep holds π × 9² × 4 ≈ 1,018 cubic feet, about 7,614 gallons.
When you need surface area instead
Volume is what a container holds; surface area is how much material covers it. You need surface area to estimate paint for a box or a tank, wrapping paper for a gift, or insulation for a water heater. The calculator counts every face, including the top and bottom. For an open-top box, subtract one length × width. For a cylinder without a lid, subtract one πr².
For flat shapes, such as the floor of a room or a lawn, use the area calculator.
Measuring tips
- Measure inside dimensions to know what something holds, and outside dimensions to know the space it takes up.
- Measure across the widest part of a circle to get the diameter, then halve it for the radius.
- Keep every measurement in the same unit. Mixing feet and inches is the most common reason a volume comes out 12 or 144 times too big.
Scaling, displacement and metric volume
Volume grows with the cube of size. Doubling every dimension of a box multiplies its volume by 2 × 2 × 2 = 8. A sphere with a 12-inch radius holds about 7,238 cubic inches, eight times the 904.8 in a 6-inch sphere. Surface area only grows four times, which is why larger tanks hold more per square foot of material.
For an object without a regular shape, such as a rock or a part, measure the water it displaces. Put it in a straight-sided container of water and measure how far the level rises. If the container’s base is 10 × 8 inches and the water rises 1.5 inches, the object’s volume is 10 × 8 × 1.5 = 120 cubic inches.
Metric units are simpler: 1 liter is 1,000 cubic centimeters, and 1 cubic meter is 1,000 liters. A box 50 × 40 × 30 cm holds 60,000 cm³, which is 60 liters.
Ordering bulk materials
Landscape and building materials are sold by volume, so the box and cylinder modes cover most jobs. Treat a flat layer as a very shallow box, with the depth converted to the same unit as the length and width.
- Mulch: a 3-inch layer over 200 square feet is 200 × 0.25 = 50 cubic feet, about 1.85 cubic yards. In 2-cubic-foot bags, that is 25 bags.
- Round footings: a post hole 12 inches across and 4 feet deep is a cylinder with a radius of 0.5 foot, so it holds π × 0.5² × 4 ≈ 3.14 cubic feet, about 0.12 cubic yard. Multiply by the number of holes, and subtract the volume of the post if it sits in the concrete.
- Gravel under a shed: work out the cubic yards, then ask the supplier how many tons a yard of that material weighs, since density varies by product.
Suppliers usually recommend ordering a little extra for settling, uneven ground and spillage; their own guidance for the specific material is the one to follow.
Sources & assumptions
How this calculator gets its numbers. Full method: our methodology.
- Box LWH, cube s³, cylinder πr²h, sphere (4/3)πr³, hemisphere (2/3)πr³, cone and pyramid one-third of base × height, capsule a cylinder plus a sphere.
- Surface area includes every face, including the bases; the pyramid assumes the top is directly over the center of its base.
- 1 US gallon = 231 in³ = 3.785411784 L; 1 yd³ = 27 ft³; 1 ft = 0.3048 m.
Sources
- OpenStax (Rice University), Prealgebra 2e, 9.6 Solve Geometry Applications: Volume and Surface Area. Volume and surface area of a rectangular solid (Example 9.47: 14 × 9 × 17 cm; Example 9.48: a 30 × 25 × 20 in crate), cube (Example 9.49: 2.5 in), sphere (Example 9.51: radius 6 in), cylinder (Example 9.53: radius 3 in, height 5 in) and the volume of a cone, one-third of a cylinder with the same base and height.
- National Institute of Standards and Technology, NIST Guide to the SI, Appendix B.8: Factors for Units Listed Alphabetically. Conversion factors: 1 oz (avoirdupois) = 28.34952 g, 1 lb = 0.4535924 kg, 1 U.S. fl oz = 29.57353 mL, 1 U.S. gallon = 3.785412 L.
- National Institute of Standards and Technology, U.S. Survey Foot: Revised Unit Conversion Factors. Since January 1, 2023 the foot is 0.3048 m exactly; 1 acre = 43,560 ft² = 4,046.8564224 m², 1 mile = 5,280 ft and 1 acre-foot = 43,560 ft³.
Last reviewed . Real containers have wall thickness and rounded corners; measure the inside for capacity.
Frequently asked questions
How do I calculate volume?
Use the formula for the shape. For a box, multiply length × width × height: a 30 × 25 × 20 inch crate holds 15,000 cubic inches. For a cylinder, multiply π × radius² × height.
How do I find the volume of a cylinder?
Multiply π by the radius squared and by the height. A radius of 3 inches and height of 5 inches gives 45π, about 141.4 cubic inches.
How many gallons are in a cubic foot?
About 7.48 US gallons. A gallon is 231 cubic inches and a cubic foot is 1,728 cubic inches, and 1,728 ÷ 231 ≈ 7.48.
How do I convert cubic feet to cubic yards?
Divide by 27, because a yard is 3 feet and 3 × 3 × 3 = 27. 54 cubic feet is 2 cubic yards.
What is the difference between volume and surface area?
Volume measures the space inside a solid, in cubic units. Surface area measures the total area of its outside faces, in square units.
How do I find the volume of a sphere?
Multiply 4/3 by π and by the radius cubed. A 6-inch radius gives 288π, about 904.8 cubic inches.