Irregular Polygon Area Calculator
Area of any straight-sided shape from its corner coordinates by the shoelace formula, with the perimeter, the area-weighted centroid and the winding direction.
Irregular Polygon Area Calculator
Background.
Any shape with straight sides can be measured from its corners alone. Give the x and y of each corner, in the order you meet them walking round the outline, and the enclosed area follows from a short run of multiplications: no splitting into triangles, no angles, no heights, and no need for the shape to be convex or regular.
The method is the shoelace formula, which surveyors know as the surveyor's area formula and mathematicians also call Gauss's area formula. Write the coordinates in two columns, multiply each x by the y on the row below, subtract the products taken the other way, add everything and halve the result. The diagonal criss-cross of those products down the columns is where the name comes from. For a simple polygon the result is exact.
Corners from a site survey, a CAD drawing or a sheet of graph paper all work. You get the area in the square of your coordinate unit, the perimeter including the closing side, the centroid (the point a flat plate of that shape would balance on, which is generally not the average of the corners), and the direction you listed the corners in. The starting outline is an L shape, 6 units wide and 7 tall with a 3-by-3 notch taken out of one corner, enclosing 33 square units.
The formula has one hard condition: the outline must not cross itself. On a crossed outline part of the boundary runs clockwise and part anticlockwise, the two lobes partly cancel, and the sum produces a believable but wrong number. Every pair of non-adjacent sides is therefore tested for a crossing first, and an outline that fails is rejected with the two offending sides named.
What is irregular polygon area calculator?
The shoelace formula gives the area of a simple polygon, one whose sides meet only at their shared corners, from its vertex coordinates: A = ½ Σ (xᵢyᵢ₊₁ − xᵢ₊₁yᵢ), with the last corner wrapping round to the first. Each term is twice the signed area of the triangle formed by the origin and one side; going round the loop, the parts lying outside the polygon are added once and subtracted once, leaving twice the polygon's area. Bart Braden's 1986 article in The College Mathematics Journal derives it from Green's theorem, where the area inside a closed curve is ½ ∮ (x dy − y dx). As Wolfram MathWorld states, the sum is positive when the corners run anticlockwise and negative when they run clockwise.
How to use this calculator.
- List the corners in the order you meet them going round the boundary. Either direction works and any corner can come first.
- Put one corner on each line with x and y separated by a comma or a space, such as "6, 4" or "6 4". A semicolon can also separate one corner from the next, so "0, 0; 6, 0; 6, 4" works on a single line. Negatives and decimals are fine, up to 200 corners.
- If your list closes the ring by repeating the first corner at the end, as many GIS and CAD exports do, leave it in: the repeat is dropped, and the corner count shows what was used.
- Keep every coordinate in one unit. Metre coordinates give square metres and feet give square feet; latitude and longitude must be projected onto a flat grid first.
- If the outline is rejected as crossing itself, use the two sides named in the message to find the corners that are out of order, and swap them.
The formula.
For each side, from corner i to corner i + 1, form the cross product cᵢ = xᵢyᵢ₊₁ − xᵢ₊₁yᵢ. The signed area is A = ½ Σ cᵢ, and the area reported is its absolute value. The centroid reuses the same products, weighted by position: x̄ = Σ (xᵢ + xᵢ₊₁)cᵢ ÷ 6A and ȳ = Σ (yᵢ + yᵢ₊₁)cᵢ ÷ 6A, the expressions in MathWorld's Geometric Centroid entry. Reversing the corner order flips the sign of every cᵢ and of A together, so the centroid is the same whichever way round you list them; only the signed area and the winding direction change. The perimeter is the sum of the straight-line lengths √((xᵢ₊₁ − xᵢ)² + (yᵢ₊₁ − yᵢ)²) of all sides, closing side included. Before any of this, every pair of sides that do not share a corner is tested for a crossing. Corners lying in a straight line are allowed, but an outline needs at least three distinct corners, two consecutive corners may not be the same point, and a set of corners that encloses zero area is rejected.
A worked example.
Take the default outline, listed anticlockwise from the origin: (0, 0), (6, 0), (6, 4), (3, 4), (3, 7), (0, 7). The six cross products, side by side, are 0 × 0 − 6 × 0 = 0, then 6 × 4 − 6 × 0 = 24, 6 × 4 − 3 × 4 = 12, 3 × 7 − 3 × 4 = 9, 3 × 7 − 0 × 7 = 21, and 0 × 0 − 0 × 7 = 0. They sum to 66, so the signed area is 66 ÷ 2 = 33, positive because the corners run anticlockwise, and the area is 33 square units. The sides measure 6, 4, 3, 3, 3 and 7, a perimeter of 26. For the centroid, Σ (xᵢ + xᵢ₊₁)cᵢ = 6 × 0 + 12 × 24 + 9 × 12 + 6 × 9 + 3 × 21 + 0 × 0 = 513, and Σ (yᵢ + yᵢ₊₁)cᵢ = 0 × 0 + 4 × 24 + 8 × 12 + 11 × 9 + 14 × 21 + 7 × 0 = 585. With 6A = 198, x̄ = 513 ÷ 198 = 2.5909 and ȳ = 585 ÷ 198 = 2.9545. The shape also splits into a 6 × 4 rectangle centred at (3, 2) and a 3 × 3 square centred at (1.5, 5.5). Their areas, 24 + 9 = 33, agree, and so does the area-weighted centre: (24 × 3 + 9 × 1.5) ÷ 33 = 2.5909 and (24 × 2 + 9 × 5.5) ÷ 33 = 2.9545.
Frequently asked questions.
What happens if I list two corners in the wrong order?
Will every ordering mistake be caught?
Why isn't the centroid just the average of the corners?
Why is the signed area sometimes negative?
Can I paste latitude and longitude?
How do I measure a shape with a hole in it?
References& sources.
- [1]Wolfram Research, MathWorld — ‘Polygon Area’ (live revision retrieved 2026-07-29). Equation (4), A = ½ Σᵢ₌₁ⁿ (xᵢyᵢ₊₁ − xᵢ₊₁yᵢ); the statement that the area ‘is defined to be positive if the points are arranged in a counterclockwise order and negative if they are in clockwise order’; and the restriction of the formula to ‘a planar non-self-intersecting polygon’, which is why this page rejects crossed outlines instead of measuring them. Open access.
- [2]Wolfram Research, MathWorld — ‘Geometric Centroid’ (live revision retrieved 2026-07-29). Equations (8) and (9), x̄ = 1/(6A) Σ (xᵢ + xᵢ₊₁)(xᵢyᵢ₊₁ − xᵢ₊₁yᵢ) and the matching expression for ȳ, with xₙ₊₁ = x₁ and yₙ₊₁ = y₁. This is the area-weighted centre of mass reported here, and it is the reason the page does not simply average the corners. Open access.
- [3]Braden, Bart. ‘The Surveyor's Area Formula.’ The College Mathematics Journal 17, no. 4 (1986): 326–337, DOI 10.1080/07468342.1986.11972974. Peer-reviewed derivation of the same formula from Green's theorem, A = ½ ∮ (x dy − y dx) around a closed curve, under the name the surveying profession uses. Publisher-gated; the bibliographic record and abstract are open and the full text was not retrieved. Cited for the derivation's provenance and the alternate name, not for any number on this page — since it lands on the identical expression, agreement with it could not catch an arithmetic error. The checks that can are decompositions into rectangles and triangles.
- [4]Wolfram Research, MathWorld — ‘Trapezoid’ (live revision retrieved 2026-07-29). Equation (1), A = ½(a + b)h. One of the elementary shapes this page's results are checked against by decomposition, alongside rectangles, triangles and the regular hexagon's exact area 3√3/2. Open access.
How this page was produced
- Published by
- Quanta Calculator
- Overseen by
- Daniel, Quanta Calculator Researcher
- Primary sources
- 4 cited below
- Method
- A = ½ |Σ (xᵢ yᵢ₊₁ − xᵢ₊₁ yᵢ)| , x̄ = (1⁄6A) Σ (xᵢ + xᵢ₊₁)(xᵢ yᵢ₊₁ − xᵢ₊₁ yᵢ)
- Published
- Last verified
Built with AI assistance and verified by automated tests against the cited sources — every worked example on this page is computed by the same code that runs the calculator. How we build and check calculators.
In this category
Embed
Quanta Pro
Paid features are coming later.
- All 1560 calculators remain free
- No billing is enabled