How to Calculate Average: Mean, Median, Mode and Weighted Average

Quick answer: to calculate an average, add all the numbers together, then divide by how many numbers there are. For 12, 15 and 21: 12 + 15 + 21 = 48, and 48 ÷ 3 = 16. Paste any list into the calculator below to get the mean, median, mode and more at once.

"Average" usually means the mean, but there are three common kinds of average, and choosing the right one matters — especially when a few numbers are much bigger or smaller than the rest. Here's how to calculate each, with examples.

📉
Average Calculator

Calculate the mean, median, mode, range, sum and standard deviation of a list of numbers.

Open the tool →

How to calculate the mean (the usual average)

  1. Add up all the values.
  2. Count how many values there are.
  3. Divide the total by the count.

Example — test scores of 72, 85, 90, 64 and 89:

  • Sum: 72 + 85 + 90 + 64 + 89 = 400
  • Count: 5
  • Mean: 400 ÷ 5 = 80

How to find the median

The median is the middle value when the numbers are sorted. Sort them, then:

  • Odd count: take the middle one. For 3, 7, 9, 12, 40 the median is 9.
  • Even count: average the two middle ones. For 3, 7, 9, 12, 40, 55 the median is (9 + 12) ÷ 2 = 10.5.

The median is better than the mean when there are outliers. If five people earn 30k, 32k, 35k, 38k and 400k, the mean is 107k — which describes nobody — but the median of 35k is a fair "typical" salary.

How to find the mode

The mode is the value that appears most often. In 2, 4, 4, 5, 7, 4, 9 the mode is 4. A list can have two modes (bimodal) or no mode at all if every value appears once. The mode is the only average that works for non-numbers — the most common shoe size sold, or the most popular answer in a survey.

Mean vs median vs mode: which should you use?

AverageBest forWeak spot
MeanTest scores, temperatures, most everyday dataPulled up or down by outliers
MedianHouse prices, salaries, anything with extreme valuesIgnores how far apart the values are
ModeMost common choice, size or categoryMay not exist, or there may be several

The average calculator shows all three, plus the sum, range, minimum and maximum, standard deviation and geometric mean, so you can compare them side by side.

How to calculate a weighted average

Use a weighted average when some values count more than others — like a final exam worth more than a quiz.

Weighted average = (value₁ × weight₁ + value₂ × weight₂ + …) ÷ (sum of the weights)

AssessmentScoreWeightScore × weight
Homework9220%1,840
Midterm7830%2,340
Final exam8550%4,250
Total100%8,430

Weighted average: 8,430 ÷ 100 = 84.3. The simple mean of the three scores would be 85 — close, but not the grade you'd actually get. For course grades, the grade calculator does the weighting for you and tells you what you need on the final.

How to average percentages correctly

You can only average percentages directly if they're out of the same total. Otherwise, go back to the raw numbers:

  • Quiz 1: 45 out of 50 = 90%
  • Quiz 2: 8 out of 10 = 80%
  • Wrong: (90 + 80) ÷ 2 = 85%
  • Right: (45 + 8) ÷ (50 + 10) = 53 ÷ 60 = 88.3%

The bigger quiz deserves more influence, and adding the raw scores gives it that. For more percentage maths, see how to calculate percentages or use the percentage calculator.

How to calculate an average in Excel and Google Sheets

  • =AVERAGE(A2:A20) — the mean of a range (blank cells are ignored, zeros are counted).
  • =MEDIAN(A2:A20) and =MODE(A2:A20) — median and mode.
  • =AVERAGEIF(B2:B20,"Paid",C2:C20) — the average of column C only where column B says "Paid".
  • =SUMPRODUCT(A2:A10,B2:B10)/SUM(B2:B10) — a weighted average, with values in column A and weights in column B.

Everyday averages

  • Average speed: total distance ÷ total time. Driving 120 km in 1.5 hours is 80 km/h on average — not the average of the speeds you saw on the speedometer.
  • Fuel average (mileage): distance driven ÷ fuel used. 450 km on 30 litres is 15 km per litre.
  • Monthly average: add the monthly totals and divide by the number of months. Spending of 820, 760 and 905 over three months averages 828.33 a month.

Frequently asked questions

What is the formula for average?

Average (mean) = sum of all values ÷ number of values. For 4, 8 and 9: (4 + 8 + 9) ÷ 3 = 7.

What is the difference between mean and average?

In everyday use they are the same thing — the sum divided by the count. Strictly, "average" can also mean the median or mode, so statisticians say "mean" when they mean the sum-divided-by-count average.

How do I calculate a weighted average?

Multiply each value by its weight, add the results, then divide by the total of the weights. For a test worth 60% scored 80 and homework worth 40% scored 95: (80 × 60 + 95 × 40) ÷ 100 = 86.

Can you average percentages?

Only if each percentage is based on the same total. Otherwise add up the underlying numbers first: 45/50 and 8/10 average to 53/60 = 88.3%, not (90% + 80%) ÷ 2 = 85%.

How do I calculate an average in Excel?

Use =AVERAGE(A1:A10). For a weighted average use =SUMPRODUCT(A1:A10,B1:B10)/SUM(B1:B10), where column B holds the weights.

Written by Abdur Rehman

ERP developer and AI & automation engineer who builds and maintains every tool on WebToolNest. More about me.