Search topics and sections

The Gini coefficient is a single number that shows how unevenly something, most often income or wealth, is shared among people. It runs from 0, when everyone has the same amount, to 1, when one person has everything and everyone else has nothing.[1] It is the most widely used measure of economic inequality, and it is a type of statistical dispersion measure that works for any quantity that cannot be negative.

The Italian statistician Corrado Gini (1884 to 1965) built the measure in papers from 1912 and 1914.[1][2] Agencies such as the World Bank publish it for most countries. They often call it the Gini index and show it on a scale from 0 to 100.[3]

The basic idea

The Gini coefficient measures how big a gap to expect between the incomes of two people picked at random, compared with the average income.[1] When incomes are close together, the expected gap is small. When incomes are spread far apart, it is large.

The gap is divided by the mean income so that the measure does not depend on how rich the population is overall. A gap of 1,000 dollars means a lot in a poor country and little in a rich one.[1] Doing this also means the Gini coefficient has no units, so it can be compared across countries and currencies.

The expected gap is then shown as a share of twice the mean income. Twice the mean is the largest the average gap can be, which happens when one person has all the income.[1]

  • If everyone earns the same, every gap is zero, so the Gini coefficient is 0.
  • If one person has all the income, the average gap reaches its maximum, and the Gini coefficient is 1.

The Lorenz curve picture

The Gini coefficient can also be read from a graph called the Lorenz curve. To draw it, line people up from poorest to richest. Then plot the share of the population counted so far (across) against the share of total income they earn (up).[4]

  • If income is shared equally, the curve is a straight diagonal line called the line of equality. The poorest 10% earn 10% of the income, the poorest 20% earn 20%, and so on.[1]
  • If income is unequal, the curve sags below the diagonal. In one example population, the bottom 60% earn only 30% of the income.[1]
  • The further the curve sags, the more unequal the distribution.[4]
Lorenz curve and the areas that define the Gini coefficient00.20.40.60.81Share of population, poorest firstShare of total income00.20.40.60.81Line of equalityLorenz curveABGini = A / (A + B)
A Lorenz curve sags below the line of equality. The Gini coefficient is the area AA between the two lines divided by the total area A+BA + B under the line of equality, so G=A/(A+B)G = A/(A+B).

The Gini coefficient compares two areas on this graph. Area AA lies between the line of equality and the Lorenz curve. Area BB lies under the Lorenz curve.[1]

G=AA+B=2A=1−2BG = \frac{A}{A+B} = 2A = 1 - 2B

Here GG is the Gini coefficient. Both axes run from 0 to 1, so AA and BB together fill a triangle of area 12\tfrac{1}{2}. That is why GG also equals 2A2A and 1−2B1 - 2B.[2][5]

The two extreme cases follow directly from the picture.[1]

  • Perfect equality: the Lorenz curve is the line of equality, so A=0A = 0 and G=0G = 0.
  • One person has all the income, in a very large population: the curve runs along the bottom axis until the very last person, so B=0B = 0 and G=1G = 1.

The Lorenz picture and the "expected gap" idea give the same value.[1] The World Bank defines its Gini index in both ways.[3]

Calculating it from data

Pairwise formula

For a list of nn incomes, the Gini coefficient is the average absolute difference over all pairs of people, divided by twice the mean.[6][3] This average difference is called the mean absolute difference.

G=∑i=1n∑j=1n∣xi−xj∣2n2μG = \frac{\displaystyle\sum_{i=1}^{n}\sum_{j=1}^{n} \lvert x_i - x_j \rvert}{2 n^2 \mu}
  • xix_i is the income of person ii.
  • nn is the number of people.
  • μ\mu is the mean income, which must be positive.

The double sum counts every ordered pair, including each person paired with themselves. This takes n2n^2 steps, which is slow for large data sets.

Sorted formula

Sorting the incomes first gives a faster formula. If x1′≤x2′≤⋯≤xn′x'_1 \le x'_2 \le \dots \le x'_n are the incomes in increasing order, then:[6]

G=∑i=1n(2i−n−1) xi′n2μG = \frac{\displaystyle\sum_{i=1}^{n} (2i - n - 1)\, x'_i}{n^2 \mu}

The weight 2i−n−12i - n - 1 is negative for the poorer half and positive for the richer half. So the formula grows as more income sits with higher-ranked people.

Lorenz curve formula

The area BB can be built from trapezoids under a Lorenz curve made of straight segments. This approach goes back to Gaetano Pietra in 1915.[2] With each person given equal weight, let LkL_k be the share of total income held by the poorest kk people, with L0=0L_0 = 0. Then:

G=1−2B=1−1n∑k=1n(Lk−1+Lk)G = 1 - 2B = 1 - \frac{1}{n}\sum_{k=1}^{n} \left(L_{k-1} + L_k\right)

Each term 1n⋅12(Lk−1+Lk)\tfrac{1}{n}\cdot\tfrac{1}{2}(L_{k-1}+L_k) is the area of one trapezoid of width 1n\tfrac{1}{n}.

Worked example

Take four people with incomes of 10, 20, 30, and 40 (total 100).

Person (poorest first) Income Share of total Population so far Income share so far (LkL_k)
1 10 0.10 0.25 0.10
2 20 0.20 0.50 0.30
3 30 0.30 0.75 0.60
4 40 0.40 1.00 1.00

All three formulas give the same answer.

  1. The mean is μ=100/4=25\mu = 100/4 = 25, so n2μ=16×25=400n^2\mu = 16 \times 25 = 400.
  2. Pairwise formula: the six distinct pairs differ by 10, 20, 30, 10, 20, and 10, which sum to 100. Counting both orders of each pair doubles this to 200, so G=200/(2×400)=0.25G = 200/(2 \times 400) = 0.25.
  3. Sorted formula: the weights are −3,−1,1,3-3, -1, 1, 3. The sum is −30−20+30+120=100-30 - 20 + 30 + 120 = 100, so G=100/400=0.25G = 100/400 = 0.25.
  4. Lorenz formula: (0+0.1)+(0.1+0.3)+(0.3+0.6)+(0.6+1)=3.0(0 + 0.1) + (0.1 + 0.3) + (0.3 + 0.6) + (0.6 + 1) = 3.0, so G=1−3.0/4=0.25G = 1 - 3.0/4 = 0.25.
Lorenz curve for incomes 10, 20, 30, 40 0 0.25 0.5 0.75 1 Share of population, poorest first Share of total income 0 0.1 0.3 0.6 1 Line of equality A = 0.125 B = 0.375 G = 1 − 2B = 0.25
Lorenz curve for four people with incomes 10, 20, 30 and 40. The four trapezoids under the curve add up to B=0.375B = 0.375, the gap above the curve is A=0.125A = 0.125, and G=1−2B=0.25G = 1 - 2B = 0.25.

Small populations

In a finite group, the Gini coefficient cannot reach 1. When one of nn people holds everything, the formulas above give (n−1)/n(n-1)/n.[2] With four people that is 3/4=0.753/4 = 0.75. The value 1 is reached only in the limit of an infinite population.[6]

Lorenz curves and Gini coefficients for four people Equal: 25, 25, 25, 25 10, 20, 30, 40 One has all: 0, 0, 0, 100 00.250.50.751 00.250.50.751 00.250.50.751 G = 0 G = 0.25 G = 0.75 = (n-1)/n 1 1 1
Lorenz curves for four people with three income splits. The blue area between each curve and the dashed line of equality is half of GG. When one person has everything, a small triangle still lies under the last segment, so G=(n−1)/n=0.75G = (n-1)/n = 0.75 rather than 1.

This matters when the data come from a sample. MathWorld notes that the sample formulas above must be multiplied by n/(n−1)n/(n-1) to estimate the Gini coefficient of the whole population without systematic error.[6]

Continuous distributions

For a smooth model of income, the pairwise idea becomes an expected value. If XX and YY are the incomes of two people drawn independently from the same distribution with mean μ>0\mu > 0, then:[3][1]

G=E ∣X−Y∣2μG = \frac{\mathbb{E}\,\lvert X - Y \rvert}{2\mu}

Here E\mathbb{E} means expected value, the long-run average over many random draws. So the top line is the average gap between two randomly drawn incomes.

The Lorenz form also carries over. If L(p)L(p) is the share of income held by the poorest fraction pp of the population, then G=1−2∫01L(p) dpG = 1 - 2\int_0^1 L(p)\,dp.[5]

Two income models used in economics have simple Gini formulas.

Model Parameter Gini coefficient
Pareto distribution shape a>1a > 1 12a−1\dfrac{1}{2a - 1}
Log-normal distribution σ\sigma, the standard deviation of log income 2Φ ⁣(σ/2)−12\Phi\!\left(\sigma/\sqrt{2}\right) - 1

In the log-normal formula, Φ(z)\Phi(z) is the cumulative distribution function of the standard normal distribution: the probability that a standard normal value is at most zz.[5] A larger σ\sigma means incomes are more spread out and gives a larger GG.

The Pareto shape aa controls how much income sits at the very top. A smaller aa puts more income at the top and gives a higher Gini coefficient. A shape of a=5a = 5 gives G=1/9≈0.111G = 1/9 \approx 0.111, and GG approaches 1 as aa falls toward 1.[7][8]

Properties

The Gini coefficient meets four properties that are widely treated as basic requirements for an inequality measure.[9][4]

  • Anonymity: only the incomes matter, not who earns them. Swapping people's labels does not change the value.
  • Population principle: copying a whole population, so every income appears twice as often, leaves the value unchanged. This lets small and large countries be compared.
  • Scale invariance: raising every income by the same percentage leaves the value unchanged. Only relative incomes count.
  • Transfer principle: moving income from a richer person to a poorer one, while the receiver stays poorer, lowers inequality. This is also called the Pigou-Dalton principle.

These four properties make a measure agree with comparisons of Lorenz curves. Economist Anthony Atkinson showed that when one Lorenz curve lies everywhere above another, every measure with these properties ranks the first distribution as more equal.[9] Ferreira groups common measures by how they respond when a poorer person gives income to a richer one.[9]

  • Strongly consistent: any such transfer raises the measure. The Gini coefficient, the Theil indices, and the Atkinson measures are in this group.
  • Weakly consistent: such a transfer only must not lower the measure. Top income shares, such as the share of the richest 1% or 10%, are in this group.
  • Inconsistent: the measure can rank a distribution as less unequal even when its Lorenz curve lies everywhere below the other. Quantile ratios, such as the income at the 90th percentile divided by the income at the 10th, are in this group.

Limitations

Same number, different shapes

Two different Lorenz curves can give the same Gini coefficient.[3] This happens when the curves cross. One society may be more unequal at the bottom, the other at the top.[4]

The example below has two four-person groups with a total income of 100 each. Both have G=0.25G = 0.25, yet their Lorenz curves cross.

Group Incomes L1L_1 L2L_2 L3L_3 Gini
X 10, 20, 30, 40 0.10 0.30 0.60 0.25
Y 5, 25, 35, 35 0.05 0.30 0.65 0.25
Two crossing Lorenz curves with equal Gini coefficients 00.250.50.751 Share of population, poorest first Share of total income 0.250.50.751 Both G = 0.25 X: 10, 20, 30, 40 X more unequal at the top Y more unequal at the bottom Y: 5, 25, 35, 35
Two Lorenz curves cross at the median: curve X (income shares 10, 20, 30, 40 percent by quartile) and curve Y (5, 25, 35, 35 percent). Both enclose the same area with the line of equality, so both have G=0.25G = 0.25, but Y is more unequal among the poorest and X is more unequal at the top.

Group Y's poorest person is worse off than in group X, but its top earner has less. A single number cannot show this trade-off, so analysts are advised to plot Lorenz curves and use more than one measure.[9]

Where it is most sensitive

The Gini coefficient reacts most to changes near the middle of the distribution and less to changes at the very top and bottom.[1][4] The effect of each income on the index depends on its rank, so very large gaps at the top move it relatively little.[9] Our World in Data shows that modest changes in the Gini coefficient can come with much larger changes in the share of income going to the richest 1%.[1]

Other limits

  • Relative, not absolute: a country's Gini coefficient can rise while the number of people in absolute poverty falls.[3]
  • Not additive: a country's Gini coefficient is not the sum of the Gini coefficients of its regions or groups. Country values cannot be combined into a regional or global value, though a Gini coefficient can be computed for the pooled data.[3]
  • Negative values: with debts, wealth can be negative, and the Gini coefficient can then exceed 1. Negative values are usually dropped or set to zero.[1]
  • Data differences: surveys differ in method and in whether they measure income or consumption. Income is usually more unequal than consumption, so values are not strictly comparable across countries or years.[3]

Comparison with other measures

Every inequality measure weights gaps in different parts of the distribution differently, so each one carries a value judgment.[1] The table summarizes how common measures differ.

Measure Most sensitive to Notes
Gini coefficient Middle of the distribution Ranges from 0 to 1; not additive across groups[4][3]
Theil index (T) Top of the distribution Splits into within-group and between-group parts; not capped at 1[4]
Theil L (mean log deviation) Bottom of the distribution Also splits into group parts[4]
Coefficient of variation Richest people The standard deviation divided by the mean[4][1]
Atkinson index Set by a chosen inequality-aversion parameter Makes its value judgment explicit[9]
Top income shares Top of the distribution Only weakly consistent with Lorenz rankings[9]
Palma ratio and decile ratios Bottom and top groups Decile ratios divide the income at one percentile by another, such as the 90th by the 10th, and ignore incomes in between; both are more sensitive than the Gini coefficient at the bottom[4]

Values around the world

Most countries have a Gini coefficient for disposable household income between 0.3 and 0.5.[4] In one comparison, values ranged from 0.27 in Belgium and Norway to 0.62 in South Africa.[4]

Range Usual reading Examples given by the source
Below 0.3 Low inequality Scandinavian countries, Slovenia, Czech Republic, Slovakia
0.3 to 0.5 Typical Most countries
Above 0.5 Very unequal Botswana, Colombia, Zambia

The World Bank tracks the number of economies with high inequality, which it defines as a Gini index above 40 (0.4 on the 0 to 1 scale).[3]

Income inequality has risen in many advanced economies since the 1980s.[4]

World Bank values come from more than 2,000 household surveys across 169 countries. Where possible it uses consumption rather than income, and data for high-income economies come mostly from the Luxembourg Income Study.[3]

History

The measure grew from two separate lines of work that were joined in the 1910s.[2]

  1. 1905: Max O. Lorenz proposed the curve now named after him. His first examples compared Prussian incomes in 1892 and 1901.[2]
  2. 1912: Corrado Gini proposed the mean difference, the average gap between values, as a measure of variability.[2]
  3. 1914: Gini proposed a concentration ratio built from the mean difference. He noted that the area between the Lorenz curve and the line of equality, divided by its largest possible value, gives the same result when the number of cases is very large.[2]
  4. 1915: Gaetano Pietra showed the exact link in the discrete case. He gave the expression used today for the Gini index and first defined the ratio for continuous distributions.[2]

So the modern Gini coefficient differs slightly from Gini's original 1914 ratio when there are only a few values. The two agree as the number of values grows.[2]

Other uses

The Gini coefficient can measure the inequality of any distribution of non-negative amounts, not only income. Our World in Data notes its use for wealth and even life expectancy.[1]

In credit scoring, "Gini" names a related measure of how well a model ranks borrowers by risk. It is computed from the area under the ROC curve (AUC) as Gini=2 AUC−1\text{Gini} = 2\,\text{AUC} - 1.[10] This version, also called the accuracy ratio, depends only on the order in which the model ranks cases.[11]

References

  1. Measuring inequality: what is the Gini coefficient?, Our World in Data (Joe Hasell), 2023.
  2. The Gini Coefficient: Its Origins, Simone Pellegrino, University of Turin, 2020.
  3. Gini index (SI.POV.GINI), Metadata Glossary, World Bank DataBank, 2026.
  4. Measuring income inequality, Ija Trapeznikova, IZA World of Labor, 2019.
  5. Estimation of the Gini coefficient for the lognormal distribution of income using the Lorenz curve, Darkwah, Nortey and Lotsi, SpringerPlus, 2016.
  6. Gini Coefficient, Christian Damgaard, in Eric W. Weisstein's Wolfram MathWorld, 2000.
  7. Estimating Pareto's constant and Gini coefficient of the Pareto distribution, Brian C. Hodge, University of Nevada, Las Vegas, 1996.
  8. Income inequality worksheet, Gonzaga University, 2023.
  9. In defense of the Gini coefficient, Francisco Ferreira, World Bank Blogs, 2020.
  10. Credit Scoring and the Optimization concerning Area under the curve, Anne Kraus and Helmut Küchenhoff, Credit Scoring and Credit Control XIII conference, University of Edinburgh, 2013.
  11. Gini Coefficient and AUC in Assessing Predictive Model Performance: Effect of Ranks, Erkki K. Laitinen, Theoretical Economics Letters, 2025.

Figure