Percentage Calculator
Pick one of three modes — X% of Y, Change from A to B, or X is what % of Y — enter the two numbers in the X and Y boxes, and press Calculate for discounts, markups, growth rates, and shares.
Percentage Calculator online
Calculate X% of Y, the percentage change from A to B, or X as a percentage of Y — the three percentage questions that come up in prices, scores, growth and discounts, with the traps that make them go wrong.
How it works
Each mode applies its own formula. X% of Y computes X ÷ 100 × Y and returns a plain number with no percent sign. Change from A to B computes (B − A) ÷ A × 100 with X as the old value A and Y as the new value B, returning a % figure that is negative for decreases. X is what % of Y computes X ÷ Y × 100 and returns a % figure. The two percent modes round to at most four decimals with trailing zeros stripped, so 66.66666…% displays as 66.6667%. Empty or non-numeric boxes show Enter two valid numbers., and a zero divisor shows Cannot divide by zero.
Worked example
A $200 jacket at 15% off: mode X% of Y with X = 15 and Y = 200 gives 15 ÷ 100 × 200 = 30, so the discount is $30 and the price is $170. A subscriber count rising from 80 to 100: mode Change from A to B with X = 80 and Y = 100 gives (100 − 80) ÷ 80 × 100 = 25% growth. A quiz score of 45 out of 180: mode X is what % of Y with X = 45 and Y = 180 gives 45 ÷ 180 × 100 = 25%.
Options
- X% of Y: portions and discounts — answer is a plain amount.
- Change from A to B: growth or decline between an old value X and a new value Y — answer carries a % sign.
- X is what % of Y: shares and rates — answer carries a % sign.
Practical tips
- Order matters in Change mode. X must be the starting value and Y the ending value; swapping 80 and 100 turns +25% into −20%.
- Read the % sign. Only the Change and What-% modes append %; the X%-of-Y answer of
30means 30 units of currency, items, or points — not 30%. - Expect four-decimal rounding. A share like 10 out of 3 shows
333.3333%, which is exact enough for reporting but should not be chained into further precise math. - Zero baselines are rejected. Growth from 0 has no defined percentage, so the page answers
Cannot divide by zero.instead of guessing.
Edge cases and limitations
- Percent is not percentage points. A rate rising from 5% to 6% is up 1 percentage point but up 20% relatively. News reports swap these constantly; Change mode here always computes the relative change.
- Chained changes multiply, they do not add. Two successive 10% discounts give 0.9 × 0.9 = 0.81 — a 19% total reduction, not 20%. The same applies to growth followed by decline: +50% then −50% nets −25%, never zero.
- The way back is steeper. After a 20% fall, a price of 80 needs a 25% rise to return to 100. Losses and gains are asymmetric because the base changes; a 50% loss needs a 100% gain.
- Direction flips the answer. Going from 80 to 100 is +25%, but 100 back to 80 is −20% — the same pair of numbers, a different base. When a result surprises you, check which value the tool used as the base (the "from" value).
Privacy and browser processing
The calculation runs entirely in your browser — the numbers you enter are never uploaded.
Frequently asked questions
Why does 15% of 200 return 30 with no percent sign?
The X% of Y mode answers an amount, not a rate: 15 ÷ 100 × 200 = 30, meaning $30, 30 items, or 30 points depending on your Y units.
How do I calculate a price decrease, say from 100 to 80?
Use Change from A to B with X = 100 and Y = 80. The result is (80 − 100) ÷ 100 × 100 = -20%, where the minus sign marks a decrease.
What is the difference between Change mode and What-% mode?
Change mode divides the difference by the starting value, so 80 → 100 is 25%. What-% mode divides X directly by Y, so 45 out of 180 is also 25% but answers a share, not a movement.
When does the Cannot divide by zero message appear?
In Change mode when X (the old value) is 0, and in What-% mode when Y is 0 — for example, asking what percent 45 is of 0. Both need a nonzero divisor, so enter a valid baseline.