Skip to main content

What percentage is X of Y?

Calculate what percentage one value is of a total: a test score as a percentage, a success rate, a share of a budget or a proportion in a survey sample. Formula part ÷ total × 100, worked examples and common mistakes.

Embed this widget

Customize the result, check the live preview, then copy the code.

Preview

Embed code type

Code to copy

Responsive and automatically resized by Bethemesh.

Percentage

-

Was this tool useful?

How does this tool work?

This page calculates the share a value represents of a total, as a percentage: 30 out of 150, 34 correct answers out of 40, 18 positive replies out of 25, $1,300 of rent on $4,000 of income. It is the calculation you need to turn a score into a percentage, measure a success rate, analyze a budget or report survey results.

The percentage is the part divided by the total, multiplied by 100: p = part ÷ total × 100. For 30 out of 150: 30 ÷ 150 = 0.2, or 20%. This amounts to rewriting the fraction 30/150 with a denominator of 100.

The total is the reference: it is the value that equals 100%. A classic mistake is swapping the two numbers, which gives 500% instead of 20%. If the part is larger than the total, the percentage goes above 100%: that is normal for an exceeded target, for example 130 sales against a target of 100, or 130%.

Both values must be in the same unit. To compare 45 minutes with 2 hours, convert to minutes first: 45 out of 120 = 37.5%. The total cannot be zero; in that case no result is shown.

The result is rounded to two decimal places. For a survey, keep the sample size in mind: 3 answers out of 4 is 75%, just like 750 out of 1,000, but the second figure is far more reliable.

How to use this tool

  1. Enter the part

    The value whose weight you want: points scored, spending in one category, positive answers...

  2. Enter the total

    The reference value that equals 100%.

  3. Read the percentage

    It appears immediately, rounded to two decimal places.

The formula for a proportion as a percentage

Divide the part by the total, then express the quotient per 100.

Percentage of a part

p = part ÷ total × 100

The total equals 100%.

Score out of 50

p = score × 2

Shortcut for a score n out of 50.

Finding the part

part = total × p ÷ 100

Reverse operation.

p
percentage you are looking for
part
value being measured
total
reference value, not zero

Example: 27 out of 36 = 0.75, or 75%.

Use cases

Tests and exams

Turn a score out of 40 or 50, or a multiple-choice result, into a percentage.

Personal budget

Measure how much of your monthly income goes to rent, groceries or savings.

Statistics and surveys

Turn counts into proportions to report results or compare groups of different sizes.

Goal tracking

Calculate a sales target attainment rate, an occupancy rate or project progress.

Examples

Basic calculation

30 ÷ 150 × 100 = 20%.

Input

30 out of 150

Result

20%

Test score

34 ÷ 40 × 100 = 85% of the questions.

Input

34 correct answers out of 40

Result

85%

Rent-to-income ratio

Share of income spent on housing.

Input

$1,300 rent on $4,000 monthly income

Result

32.5%

Survey result

18 ÷ 25 × 100 = 72%.

Input

18 positive replies out of 25

Result

72%

Target exceeded

The part is larger than the total: the target is met at 130%.

Input

130 sales against a target of 100

Result

130%

Tips and best practices

  • The total, the value that equals 100%, always goes in the denominator.
  • Convert both values to the same unit before calculating.
  • A percentage above 100% means the part exceeds the reference, which is not an error.
  • To compare two years, you need a percentage change, calculated on the percentage increase or decrease page.
  • Report the sample size next to any survey percentage.

Sources and references

Frequently asked questions

How do I calculate what percentage one number is of another?

Divide the number by the total, then multiply by 100. 45 out of 180: 45 ÷ 180 × 100 = 25%.

How do I turn a test score into a percentage?

Divide the number of correct answers by the number of questions and multiply by 100. On a 50-question test, simply multiply by 2: 43 out of 50 = 86%. On a 40-question test, multiply by 2.5: 37 out of 40 = 92.5%.

How do I calculate a success rate?

Divide the number of successes by the total number of attempts, then multiply by 100. 42 students passing out of 48 gives a pass rate of 87.5%.

Why do I get a percentage above 100%?

Because the value you entered is larger than the total. That is correct when the part can exceed the reference (a target beaten); otherwise, check that the two numbers are not swapped.

How is this different from calculating X% of a number?

Here you find the percentage from the part and the total: 30 out of 150 = 20%. The reverse calculation starts from the percentage to find the part: 20% of 150 = 30.

Related tools

Tools similar or complementary to this one.

Similar tools

Find a percentage of any value: 20% of 150, 8% sales tax on a price or a 20% tip on a bill.

Mathematics & calculationUse this tool

Rescale a grade out of 20, 10, 100 or any maximum to another scale, with its percentage, by simple proportion.

Mathematics & calculationNewUse this tool