Skip to content
Omnikalc

Cuboid calculator: volume, surface area and diagonal of a box

Enter the length, the width and the height of a cuboid to get its volume, capacity in gallons, surface areas, space diagonal and the sum of its edges.

Updated on
Your inputs

Value out of range

Value out of range

Value out of range

Results

Volume

576.00 in³

Capacity in US gallons
2.49 gal
Total surface area
432.00 in²
Lateral surface area (four sides)
240.00 in²
Space diagonal
15.620 in
Sum of the 12 edges
104.00 in

A cuboid is the shape of a box, a room, a brick or a fish tank, and four or five numbers describe it fully. This cuboid calculator takes the length, the width and the height to give the volume, the capacity in gallons, the total surface area, the lateral surface area, the space diagonal and the sum of the edges.

How the calculation works

  • Volume = length × width × height.
  • Total surface area = 2 × (length × width + length × height + width × height), the area of the six rectangular faces.
  • Lateral surface area = 2 × height × (length + width), the four side faces without the top and bottom.
  • Space diagonal = √(length² + width² + height²), the longest straight line from one corner to the opposite corner. It comes from the Pythagorean theorem used twice.
  • Sum of the 12 edges = 4 × (length + width + height). The capacity converts the volume to US gallons, at 231 cubic inches per gallon.

Example

A box of 12 × 8 × 6 in has a volume of 12 × 8 × 6 = 576 in³, or about 2.49 gallons. The surface area is 2 × (96 + 72 + 48) = 432 in² and the lateral area is 2 × 6 × 20 = 240 in². The space diagonal is √(144 + 64 + 36) = √244 ≈ 15.62 in, and the edges add up to 4 × 26 = 104 in.

Why it matters

Volume tells you how much a box holds, surface area how much material or paint it takes and the diagonal whether a long object fits inside. The formulas come up in packaging, shipping, construction, aquariums and geometry homework.

Good to know

Use the same unit for the three sides, or let the calculator convert them for you. For capacity, measure the inside of the container and not the outside, since the walls take space. The surface area counts the outside faces once, so a box with an open top has a smaller area, which is the total minus the top. All results scale with the cube of the size for volume and with the square for area.

The volume calculator covers other solids, the regular prism calculator handles prisms with a polygon base and the rectangle diagonal calculator works in two dimensions.

Frequently asked questions

What is a cuboid?

A cuboid, also called a rectangular prism or a box, is a solid with six rectangular faces that meet at right angles. It has 8 corners and 12 edges, in three groups of four equal edges. A cube is the special case in which the length, the width and the height are equal.

What is the space diagonal used for?

The space diagonal is the longest straight distance inside the box. It tells you whether a long object, such as a rod, a pipe or a fishing rod, fits in a box diagonally. If the object is shorter than the space diagonal, it can fit when it is placed corner to corner.

How do I find the face diagonals?

A face diagonal comes from the Pythagorean theorem applied to two sides of that face. For the base, it is √(length² + width²). The space diagonal is then √(face diagonal² + height²), which gives the same result as the formula above.

How do I convert the volume to a capacity?

Divide the volume in cubic inches by 231 to get US gallons, or the volume in cubic centimeters by 1,000 to get liters. For a box in feet, multiply the cubic feet by 7.48 to get gallons. The capacity is the interior volume, so use the inside dimensions of a tank or a container.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.