Rectangular Prism Volume Calculator (Box)

Compute the volume of a rectangular box from length, width, and height.
For shipping, aquariums, storage cabinets, and rooms.

Box Volume

V = l × w × h

Length times width times height. The standard rectangular box (also called a cuboid or rectangular prism). Three perpendicular edges; six rectangular faces; eight corners.

Worked example: aquarium volume A “20 gallon long” tank measures 30" × 12" × 12" on the outside. V = 30 × 12 × 12 = 4,320 cubic inches. Convert to gallons: 4,320 / 231 = 18.7 gal.

Notice that the geometry already comes in under the label, and the real water volume is lower still. The glass takes a few percent, and nobody fills a tank to the brim, so 16 to 17 gallons of actual water is typical. “20 gallon long” is a trade name for a standard footprint, not a measurement. Dose medication or fertiliser off the measured volume, never off the badge.

Where rectangular volumes matter in real life:

  • Shipping boxes. Carriers charge on weight or dimensional weight, whichever is greater. Dimensional weight is l × w × h divided by a divisor, commonly 139 in³/lb for US domestic, so a big light box can cost as much as a small heavy one.
  • Aquariums. A US gallon is 231 in³, a UK gallon 277 in³, and a litre 1,000 cm³. Measure rather than trusting the label.
  • Rooms and HVAC sizing. Ventilation is specified in air changes per hour, which needs the volume. A 12 × 14 × 9 ft room is 1,512 ft³, or 42.8 m³.
  • Cabinet capacity. A pantry 18" × 24" wide and 72" tall is 18 ft³, since 18 × 24 × 72 = 31,104 in³ and there are 1,728 in³ in a cubic foot. That 1,728 is the number people forget, and forgetting it is how a cabinet ends up quoted at a third of its real size.
  • Cargo bays. A 20-foot intermodal container holds about 1,170 ft³ usable.
  • Refrigerators. Full-size units advertise 18 to 25 ft³ total, which is roughly one pantry cupboard.

Conversion shortcuts:

Convert Formula
cubic feet → gallons (US) × 7.48
cubic feet → liters × 28.32
cubic inches → US gallons ÷ 231
cubic meters → liters × 1,000

Rectangle vs. cuboid, and the unit that gives it away

A 2D rectangle needs two numbers, a box needs three. If your data has only two, you have a rectangle. The tell is always the unit: square feet is floor area, cubic feet is room volume, and quoting one where the other belongs is the commonest slip in room sizing.

The conversions are unforgiving for the same reason. There are 12 inches in a foot, but 144 square inches and 1,728 cubic inches. Each extra dimension multiplies the factor again, which is why a cabinet measured in inches looks enormous until you divide correctly.

Sanity check: if l = w = h, the rectangular prism collapses to a cube and V = s³. ✓


How we build and check this calculator

This calculator runs entirely in your browser, so the numbers you enter stay on your device. The math behind it is written by hand and tested against worked examples and standard references before the page goes live.

SuperGlobalCalculator is independently built and maintained. See how we build and verify our calculators.


Embed This Calculator

Copy the code below and paste it into your website or blog.
The calculator will work directly on your page.