Cube Calculator

Reviewed By CalcEagle Editorial Team How we check our math

A cube with edge length a has a volume of V = a³ and a surface area of S = 6a². A cube with 3-foot edges holds 27 cubic feet (one cubic yard, about 202 US gallons) and has 54 square feet of surface.

Enter any one measurement (edge, volume, surface area, face diagonal or space diagonal) and the calculator finds all the others. It can also cube a single number, such as 12³ = 1,728.

What do you want to calculate?
ft

Volume uses cubic units and surface area uses square units of the length unit you pick.

Cube Calculator: V = a³   ·   S = 6a²

How to use the Cube Calculator

  1. Leave Cube (shape) selected to work with a solid cube, or choose Cube of a number (x³) to raise a number to the third power.
  2. In I know the, pick the measurement you have: edge length, volume, surface area, face diagonal or space diagonal.
  3. Type it into Value and choose the Length unit (inches, feet, yards, centimeters, meters or millimeters). A volume is read in cubic units and a surface area in square units of that length unit, as shown next to the box.
  4. Keep Also show the volume in US gallons and liters checked if you want a capacity estimate.
  5. Press Calculate to get every other measurement, with the steps.

Cube formulas

A cube has 6 identical square faces, 12 equal edges and 8 corners. Everything about it follows from the edge length a:

Volume: V = a³ Surface area: S = 6a² Face diagonal: d = a√2 ≈ 1.414214 × a Space diagonal: D = a√3 ≈ 1.732051 × a Edge from others: a = ∛V = √(S ÷ 6) = d ÷ √2 = D ÷ √3
SymbolMeaningUnit
aEdge (side) lengthin, ft, cm …
VVolume, the space insidein³, ft³, cm³ …
STotal surface area of all six facesin², ft², cm² …
dDiagonal across one face, corner to cornersame as a
DSpace diagonal, from one corner through the center to the opposite cornersame as a

Both diagonals come from the Pythagorean theorem. Across a face, d² = a² + a² = 2a². The space diagonal is the hypotenuse of a right triangle with legs d and a, so D² = 2a² + a² = 3a².

Cube diagram labeled with edge a, face diagonal a√2 and space diagonal a√3, with the volume and surface area formulas
Every cube measurement follows from the edge length a.

Example: a 3-foot cube (one cubic yard)

A storage bin, planter or water tank shaped like a cube has 3-foot edges.

MeasurementCalculationResult
Volume3³27 ft³
Surface area6 × 3²54 ft²
One face3²9 ft²
Face diagonal3 × √24.2426 ft
Space diagonal3 × √35.1962 ft
All 12 edges12 × 336 ft
US gallons27 × 1,728 in³ ÷ 231 in³201.97 gal
Liters46,656 in³ × 0.016387064 L764.55 L

Because 3 feet equals 1 yard, this cube is exactly one cubic yard: 1 yd³ = 27 ft³ = 46,656 in³. As a watertight tank with these inside dimensions it would hold about 202 US gallons.

Worked example: a cube with 3-foot edges has a volume of 27 cubic feet, a surface area of 54 square feet and holds about 202 US gallons
A 3-foot cube is one cubic yard: 27 ft³, 54 ft² of surface, about 202 gallons.

Working backward: will it fit?

The space diagonal is the longest straight line that fits inside a cube. To check whether a 40-inch rod fits in a box with 24-inch inside edges, choose Edge length, enter 24 with the unit set to inches, and read the space diagonal: 24 × √3 ≈ 41.57 in. The rod fits, corner to corner. Going the other way, if a cube must hold 1,000 in³, choose Volume: the edge is ∛1,000 = 10 in.

Cube of a number (x³)

"Cubing" a number means multiplying it by itself three times: x³ = x × x × x. That is also the volume of a cube whose edge is x. A negative number cubed stays negative, because (−2) × (−2) × (−2) = −8, and a decimal works the same way: 1.5³ = 3.375.

x1234567891012
x³1827641252163435127291,0001,728

The result also lists the square and the cube root, so you can go back and forth: ∛1,728 = 12.

How to read the result

  • Lengths (edge, diagonals, total edge length) are in the unit you chose; areas are squared units; volume is cubic units.
  • Scaling matters: doubling the edge multiplies the surface area by 4 and the volume by 8.
  • Gallons are US liquid gallons (231 cubic inches each). A liter is 1,000 cm³.
  • The inscribed sphere (radius a ÷ 2) is the largest ball that fits inside; the circumscribed sphere (radius a√3 ÷ 2) passes through all eight corners.

Assumptions and limitations

  • The shape is a perfect cube: all edges equal and all angles 90°. For a box with different length, width and height, the cube formulas don't apply.
  • Containers have wall thickness. Use inside dimensions for capacity and outside dimensions for space taken up or material needed.
  • Gallon and liter figures describe geometric volume, not a safe fill level.
  • Results are rounded for display, normally to four decimal places.

Common mistakes

  • Converting cubic units with a linear factor. One foot is 12 inches, but one cubic foot is 12³ = 1,728 cubic inches, and one square foot is 144 square inches.
  • Mixing units. Measure every edge in the same unit before entering it, or the volume will be off by a large factor.
  • Confusing one face with the whole surface. A 3-foot cube has 9 ft² per face but 54 ft² in total.
  • Using the face diagonal when you need the space diagonal. The diagonal across a face (4.24 ft for a 3-foot cube) is shorter than the diagonal through the center (5.20 ft).

Need the area of a curved slice instead? Try the Area of a Sector Calculator. Planning a masonry project? The Brick Calculator estimates how many bricks a wall needs.

Frequently asked questions

How do you find the volume of a cube?

Multiply the edge length by itself three times: V = a³. A cube with 3-foot edges has a volume of 3 × 3 × 3 = 27 cubic feet.

How do you find the side length of a cube from its volume?

Take the cube root of the volume: a = ∛V. A cube that holds 1,000 cubic inches has 10-inch edges, because 10³ = 1,000.

What is the surface area of a cube?

Six times the area of one face: S = 6a². A 3-foot cube has 9 ft² per face and 54 ft² in total.

How long is the diagonal of a cube?

The diagonal across one face is a√2 (about 1.414 × a). The space diagonal through the center, corner to corner, is a√3 (about 1.732 × a). For a 3-foot cube those are 4.24 ft and 5.20 ft.

How many gallons are in a cubic foot?

One cubic foot is 1,728 cubic inches and one US gallon is 231 cubic inches, so a cubic foot holds 1,728 ÷ 231 ≈ 7.48 US gallons (about 28.32 liters).

Sources and references

  1. Cube — Wolfram MathWorld
  2. Handbook 44 (2024), Appendix C: General Tables of Units of Measurement — National Institute of Standards and Technology (NIST)
  3. NIST Guide to the SI, Appendix B.8: Factors for Units Listed Alphabetically — National Institute of Standards and Technology (NIST)

Formulas and content last reviewed on October 13, 2026. Last updated October 13, 2026. Results are estimates for general information only. Spotted a problem? Tell us and we will check it.