Percentage Difference Calculator

Enter any two values to get the percentage difference: the gap between them relative to their average. Unlike percentage change, it doesn't matter which value comes first.

Put this calculator on your website — free

Copy one snippet and give your visitors a working Percentage Difference Calculator.

Percentage difference vs. percentage change — they are not the same thing

This distinction is the whole reason this page exists. Percentage change is directional: it measures how much a value grew or shrank relative to where it started. Going from 40 to 60 is a +50% change, but going from 60 to 40 is a −33.3% change — same two numbers, different answers, because the baseline changed. Percentage difference is symmetric: it measures the gap between two values relative to their average, so 40 vs. 60 is a 40% difference no matter which one you type first. Use percentage change when one value is a genuine "before" (last year's revenue, the original price). Use percentage difference when the two values are peers and neither deserves to be the baseline (two vendors' quotes, two thermometers' readings).

The formula

% difference = |a − b| ÷ ( (a + b) ÷ 2 ) × 100

a and b are your two values; |a − b| is the absolute gap between them, and (a + b) ÷ 2 is their average. Because the denominator treats both values equally, swapping a and b changes nothing.

Worked example

Compare 40 and 60:

Gap = |40 − 60| = 20. Average = (40 + 60) ÷ 2 = 50. Percentage difference = 20 ÷ 50 × 100 = 40%.

Contrast with percentage change on the same numbers: 40 → 60 is +50%, while 60 → 40 is −33.3%. Three different percentages from one pair of numbers — which is exactly why you should name the one you're using.

A note on misuse

Headlines and reports mix these up constantly — "50% difference between the two plans" often turns out to mean a 50% change from the cheaper one, which is only a 40% difference by the symmetric measure. When you quote a percentage comparing two numbers, say which formula you used and, ideally, give the raw values too. Also know the formula's limits: with values of opposite signs the average can hit zero and the result becomes undefined or meaningless — percentage difference is built for comparing two positive quantities.

Frequently asked questions

What is the difference between percentage difference and percentage change?

Percentage change is directional: it measures growth or decline relative to a starting value, so 40 to 60 is +50% but 60 to 40 is −33.3%. Percentage difference is symmetric: it divides the gap by the average of the two values, giving the same answer (40%) whichever number you enter first. Use change for before/after; use difference for comparing two peers.

How do I calculate percentage difference between two numbers?

Take the absolute difference between the values, divide it by the average of the two values, and multiply by 100: |a − b| ÷ ((a + b) ÷ 2) × 100. For 40 and 60: 20 ÷ 50 × 100 = 40%.

When should I use percentage difference?

Use it when neither value is a natural baseline — comparing two products' prices, two labs' measurements, two cities' rents, or two candidates' salaries. If one value is clearly the "before" or the reference standard, percentage change (or percentage error) is the better tool.

Can percentage difference be more than 100%?

Yes. When one value is much larger than the other, the gap can exceed their average. Comparing 10 and 90: the difference is 80 and the average is 50, giving 160%. The theoretical maximum for two positive values approaches 200%, reached as the smaller value approaches zero.

Why does the calculator say the result is undefined for my numbers?

The formula divides by the average of the two values, so if your values average to zero (like −5 and 5), there's nothing to divide by and the result is undefined. Percentage difference is really designed for two values of the same sign — ideally both positive.

Related calculators