A polygon's perimeter is the sum of the lengths of all its sides. The method depends on what kind of polygon you're working with.

Regular polygons (all sides equal)

For a regular polygon — like an equilateral triangle, a square, or a regular pentagon — every side has the same length, so you just multiply.

P = n × s

Where n is the number of sides and s is the length of one side.

Example

A regular pentagon (5 sides) with each side measuring 6 cm.

P = 5 × 6 = 30 cm

Irregular polygons (sides of different lengths)

Simply add up every side length:

P = a + b + c + d + …

Example

A quadrilateral with sides 4 cm, 7 cm, 5 cm, and 9 cm.

P = 4 + 7 + 5 + 9 = 25 cm

From coordinates (distance formula)

If you only know the (x, y) coordinates of each vertex, find the length of each side with the distance formula, then add them together.

d = √[(x₂−x₁)² + (y₂−y₁)²]

Example

A quadrilateral with vertices at (−1, −1), (1, −3), (6, 2), and (4, 4).

Side 1: √[(1−(−1))² + (−3−(−1))²] = √[4+4] = √8 ≈ 2.83
Side 2: √[(6−1)² + (2−(−3))²] = √[25+25] = √50 ≈ 7.07
Side 3: √[(4−6)² + (4−2)²] = √[4+4] = √8 ≈ 2.83
Side 4: √[(−1−4)² + (−1−4)²] = √[25+25] = √50 ≈ 7.07
P ≈ 2.83 + 7.07 + 2.83 + 7.07 ≈ 19.8

Quick reference

You know...Use...
All sides equal, count of sidesP = n × s
Each side lengthP = sum of all sides
Only vertex coordinatesDistance formula for each side, then sum
In the app

Get the perimeter without the algebra

Works for regular and irregular polygons alike.

  1. Open Geometry Solver² and pick your polygon from the 2D tab.
  2. Enter the sides, angles, or diagonal you know.
  3. Perimeter and area appear instantly in the Results panel.
  4. Tap "Show solution steps" to see exactly how it was calculated.
Download on the App Store
Geometry Solver calculator showing area and perimeter results for a quadrilateral