Volume of a Rectangular Prism: Formula & Calculator
The calculator for this page is switched off while it is checked. The formula is below, and the worked example in the article shows how to use it by hand.
This calculator finds the volume of a rectangular prism (a box) when you enter its length, width, and height. You get the volume in cubic units, along with the formula and a step-by-step example using your exact numbers.
Formula
The volume of a rectangular prism is the product of its three dimensions: length, width, and height.
V = l × w × h
- V = volume (cubic meters, cubic feet, etc.)
- l = length (meters, feet, etc.)
- w = width (meters, feet, etc.)
- h = height (meters, feet, etc.)
All three dimensions must be in the same unit. The volume unit is that unit cubed (m³, ft³, cm³).
Worked Example
Using the default values: length = 5 m, width = 3 m, height = 2 m.
- Multiply length by width: 5 × 3 = 15 m² (this is the area of the base).
- Multiply the base area by height: 15 × 2 = 30 m³.
The volume is 30 m³, which matches the calculator’s output.
When to Use This Formula
Use this whenever you need the space inside a rectangular box: a shipping carton, a fish tank, a concrete footing, a storage container, or a room. The same formula works for any right rectangular prism, where all faces are rectangles and all angles are 90°.
If the shape is not a rectangular prism (e.g., a cylinder, sphere, or triangular prism), you need a different formula. For a cube, where l = w = h, the formula simplifies to V = s³.
How to Read the Result
The volume tells you how many unit cubes fit inside. For example, 30 m³ means 30 cubes of 1 m × 1 m × 1 m. This is useful for:
- Calculating how much water a tank holds (1 m³ = 1000 liters).
- Estimating concrete needed for a slab (volume in m³ or yd³).
- Determining shipping volume for freight (often in cubic feet or cubic meters).
Remember that volume is three-dimensional; do not confuse it with surface area, which is the total area of all six faces (2lw + 2lh + 2wh).
Common Mistakes and Unit Mix-ups
- Mixing units: If length is in meters and width in centimeters, convert first. Use the same unit for all three.
- Forgetting to cube: Volume is always in cubic units, not square units.
- Using the wrong dimension: Ensure you measure the three perpendicular edges, not the diagonal.
- Rounding too early: In multi-step problems, keep full precision until the end.
If you have a measurement in inches and need cubic feet, divide the volume in cubic inches by 1728 (12³). For metric, divide cubic centimeters by 1,000,000 to get cubic meters.
Limits of the Formula
This formula applies only to rectangular prisms with straight, perpendicular edges. It does not work for:
- Irregular shapes with slanted sides (use displacement or integration).
- Hollow objects (subtract the inner volume).
- Prisms with non-rectangular bases (use base area × height for any prism).
For a box with different wall thicknesses, you must measure the interior dimensions, not the exterior.
Frequently Asked Questions
What is the difference between volume and capacity?
Volume is the space an object occupies, measured in cubic units. Capacity is how much a container can hold, often measured in liters or gallons. For a rectangular tank, capacity = volume × conversion factor (e.g., 1 m³ = 1000 L).
How do I find the volume if I only know the surface area?
You cannot determine volume from surface area alone—many different prisms can have the same surface area but different volumes. You need at least two dimensions and the surface area, or all three dimensions.
What if the prism is not a perfect rectangle?
If the base is a rectangle but the sides are slanted (a parallelepiped), the formula V = base area × height still works if you use the perpendicular height, not the slant height. If the base is not a rectangle, use the appropriate base area formula.
How do I convert volume from cubic feet to gallons?
One cubic foot equals approximately 7.48052 US gallons. Multiply the volume in cubic feet by 7.48052 to get gallons. For metric, 1 cubic meter equals 1000 liters.
Why is the answer in cubic units?
Because you are multiplying three linear measurements, the unit multiplies three times. For example, meters × meters × meters = cubic meters. This represents a three-dimensional space.
Can I use this formula for a cube?
Yes, a cube is a rectangular prism where all edges are equal. The formula becomes V = s × s × s = s³, where s is the side length.
Related
Formula used
in l | Length | m | 5 | 0 in w | Width | m | 3 | 0 in h | Height | m | 2 | 0 out V | Volume | m³ | l * w * h | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.