CompoundPage

Percentage difference calculator

The percentage difference calculator puts 40 and 60 at 40%: the gap of 20, divided by their average of 50. Swap them and the answer stays 40%, which is what makes this different from percentage change.

Percentage difference between 40 and 6040%

Working
|40 - 60| / |(40 + 60) / 2| x 100 = 20 / 50 x 100 = 40%
Gap between them
20
Percentage change from 40 to 60
+50%
Percentage change from 60 to 40
-33.333333%

How the Percentage Calculator works

Percentage difference is |a - b| / ((a + b) / 2) x 100: the gap between two numbers divided by their average. For 40 and 60 the gap is 20 and the average is 50, so the difference is 20 / 50 = 40%. Swap the numbers and nothing changes, which is the one thing a percent difference calculator does that a percentage change calculator does not.

Percentage difference is easy to mistake for percentage change, and the same pair of numbers shows how they part. The percentage change from 40 to 60 is 20 / 40 = +50%. The percentage change from 60 to 40 is 20 / 60 = -33.33%. The percentage difference between 40 and 60 is 20 / 50 = 40%, whichever way round.

Change has a direction and a baseline (the number you started from), so it gives two different answers depending on which way you go. Difference has neither. It divides by the average so that neither number is privileged, and lands between the two changes. That decides which one to use. If one number is a before and the other an after, or one is a reference value and the other is being judged against it, use change. If the two are peers (two shops' prices for the same item, two runs of the same experiment, the populations of two towns), use difference, because picking one as the base would be arbitrary and would change the answer.

Percent error is a third measure and a close relative of change, not of difference: |measured - accepted| / accepted. A measured gravity of 9.6 against the accepted 9.81 is a 2.14% error. Dividing by the average there would be wrong, because the accepted value is the baseline by definition.

Percentage difference has a ceiling. For two numbers of the same sign it can never exceed 200%, which it reaches when one of them is zero: 0 and 60 differ by 200%. Large gaps are squeezed toward that ceiling, so 10 and 1,000 differ by only 196.04% even though 1,000 is a hundred times 10 and the change from 10 to 1,000 is +9,900%. For numbers far apart, the ratio or the change says more.

Numbers of opposite sign break the measure. Their average shrinks toward zero, so the percentage goes past 200% and grows without limit, and if they cancel exactly, as 5 and -5 do, the average is zero and there is no answer at all. Two zeros are also undefined: they are equal, but there is no average to divide by.

Not everyone uses the average. Some fields divide the gap by the larger number (20 / 60 = 33.33% here) or the smaller (20 / 40 = 50%). When a report quotes a percentage difference, check which convention it used before comparing it with another.

Percentage Calculator FAQ

How do I calculate percentage difference?

Take the gap between the two numbers, divide by their average, and multiply by 100. For 40 and 60: 20 / 50 x 100 = 40%.

What is the difference between percentage change and percentage difference?

Percentage change has a starting point and divides by it, so 40 to 60 is +50% and 60 to 40 is -33.33%. Percentage difference has no starting point and divides by the average, so 40 and 60 differ by 40% whichever comes first.

Can a percentage difference be more than 100%?

Yes, up to 200% for two positive numbers. It hits 200% when one of them is zero, and approaches it as the numbers move far apart: 10 and 1,000 differ by 196.04%.

What if one of the numbers is negative?

Then the average is pulled toward zero and the result exceeds 200%, which describes nothing useful. If the two numbers add up to zero, the percentage difference is undefined. Compare them by the plain gap instead.

More from the Percentage Calculator

Related calculators

Embed this calculator
<div id="compoundpage-percentage-calculator"></div>
<script src="https://compoundpage.com/embed/percentage-calculator.js" async></script>

The same calculation as JSON