Area & Volume Calculator

Calculate the area and perimeter of triangles, rectangles, circles and trapezoids, and the volume and surface area of boxes, cylinders, cones and spheres. Includes the Pythagorean theorem and Heron’s formula with full working.

—
—

Formulas and working

    About the Area & Volume Calculator

    This geometry calculator works out area, perimeter, volume and surface area for 18 shapes on one page. Pick a shape, type the measurements, and you get the result together with the formula with your numbers plugged in — useful for checking homework, estimating flooring or paint, or finding how much a planter or fish tank holds.

    For a right triangle, enter any two sides and the Pythagorean theorem gives the third. For a triangle with three known sides, Heron’s formula gives the area and all three angles. Units can be millimeters, centimeters, meters, kilometers, inches, feet or yards; 3D shapes also show their capacity in liters.

    How to use

    1. Choose a shape from the list — 2D and 3D shapes are grouped separately.
    2. Choose a unit (in, ft, cm, m…). Area is shown in square units and volume in cubic units.
    3. Enter the lengths that match the letters in the diagram (a, b, h, r…). Results update as you type.
    4. Check “Formulas and working” to see each calculation step by step.

    Area and perimeter formulas

    ShapeAreaPerimeter
    Triangle½ × base × heighta + b + c
    Rectanglewidth × height2 × (w + h)
    Squarea²4a
    Circleπr²2πr
    Trapezoid(a + b) × h ÷ 2sum of all sides
    Parallelogrambase × height2 × (a + b)
    Rhombusp × q ÷ 24 × side
    Sectorπr² × θ/360arc + 2r
    Ellipseπabapproximation

    Volume and surface area formulas

    ShapeVolumeSurface area
    Cubea³6a²
    Rectangular prisml × w × h2(lw + wh + hl)
    Cylinderπr²h2πr² + 2πrh
    Cone⅓πr²hπr² + πrl (l = slant height)
    Sphere⁴⁄₃πr³4πr²
    Square pyramid⅓a²ha² + 2as (s = slant height)

    A cone or pyramid holds exactly one third of the prism or cylinder with the same base and height. 1 liter = 1,000 cm³; 1 cubic foot ≈ 28.32 liters ≈ 7.48 US gallons.

    Pythagorean theorem and Heron’s formula

    Pythagorean theorem: in a right triangle, the square of the hypotenuse equals the sum of the squares of the legs (a² + b² = c²). Well-known whole-number triples are 3-4-5, 5-12-13 and 8-15-17.

    Heron’s formula: with sides a, b and c, find the semi-perimeter s = (a + b + c) ÷ 2, then area = √(s(s − a)(s − b)(s − c)). You don’t need the height, which makes it handy for measuring plots of land.

    FAQ

    What value of π does the calculator use?

    Full double precision (3.141592653589793…), not 3.14. Results may differ slightly in the second decimal place from textbook answers that use 3.14.

    Why does it say my three sides can’t form a triangle?

    By the triangle inequality, the longest side must be shorter than the sum of the other two. For example 2, 3 and 6 fail because 2 + 3 = 5 is less than 6.

    What is the difference between surface area and lateral area?

    Lateral area covers only the sides; total surface area also includes the base(s) — both ends for a cylinder. Use the total surface area for paint or wrapping paper.

    How do I convert the volume to gallons?

    The result shows capacity in liters. Divide liters by 3.785 for US gallons, or by 4.546 for imperial gallons.

    How do I get square feet?

    Set the unit to ft and the area is shown in ft². For a room, measure length and width in feet and use the rectangle.