The centroid is the balance point of a uniform flat plate. In a triangle it is where the three medians meet, two-thirds of the way from each vertex. Structural engineers use centroids to find neutral axes of beams.
How to use the Centroid Calculator
- Shape
- x₁
- y₁
- x₂
- y₂
- x₃
- y₃
- x-coordinates (in order)
- y-coordinates (same order)
Results update as you type, and everything is calculated in your browser.
How it works
For a triangle or a set of points the centroid is the average of the coordinates. For a polygon the area-weighted formula is used, which differs from the plain average for most shapes.
Inputs explained
| Field | What to enter |
|---|---|
| Shape | Choose one: Triangle, Set of points (average), Polygon (area centroid) |
| x₁ | A number |
| y₁ | A number |
| x₂ | A number |
| y₂ | A number |
| x₃ | A number |
| y₃ | A number |
| x-coordinates (in order) | A list of numbers separated by commas, spaces or new lines |
| y-coordinates (same order) | A list of numbers separated by commas, spaces or new lines |
Formula
Triangle: G = ((x₁ + x₂ + x₃)/3, (y₁ + y₂ + y₃)/3)
Polygon: Cx = Σ(xᵢ + xᵢ₊₁)(xᵢyᵢ₊₁ − xᵢ₊₁yᵢ) / (6A)
Worked example
Inputs — Shape: Triangle; x₁: 0; y₁: 0; x₂: 6; y₂: 0; x₃: 3; y₃: 6.
Results — Centroid x = 3; Centroid y = 2; Area = 18.
Key terms
- Median
- A segment from a vertex to the midpoint of the opposite side.
Frequently asked questions
Where is the centroid of a triangle?
At the intersection of the medians, 2/3 of the way from each vertex.
Is the polygon centroid the average of its vertices?
Not in general – only for triangles and some symmetric shapes.
Can the centroid lie outside the shape?
Yes, for non-convex shapes like an L or a crescent.
What is the difference from the center of mass?
The centroid is the center of mass of a uniform shape.