Weighted Average Calculator

This weighted average calculator takes a list of values and a matching list of weights and returns the weighted mean, the plain unweighted mean, and the gap between them. A table breaks it down item by item: value, weight, value × weight and share of the total.

Weighted average calculatorLive — updates as you type
Scores, grades, prices — whatever you are averaging.
Percentages, credits or decimals. They do not have to add up to 1.

How to use the weighted average calculator

  1. Put your values in the first box: scores, prices, ratings, whatever you are averaging.
  2. Put the matching weights in the second box, in the same order. The first weight belongs to the first value, the second to the second, and so on.
  3. Results update as you type. If the two lists are different lengths, the calculator says so instead of guessing which item you meant to leave out.
  4. Read the weighted average at the top, and compare it with the unweighted mean shown just below.
  5. Check the breakdown table to see each item’s value × weight and what percentage of the total weight it carries.

Weights can be percentages (15, 20, 25, 40), decimals (0.15, 0.2, 0.25, 0.4), credit hours (4, 3, 4, 1) or raw quantities (100, 50, 25). All four give the same answer as long as they are in proportion to each other.

The weighted average formula

weighted average = Σ(value × weight) ÷ Σ(weights)
Multiply each value by its weight, add up the products, then divide by the total weight.

Three steps, in order. Multiply each value by its own weight. Add those products together. Divide by the sum of the weights, not by how many items there are.

That last point is the whole difference. A plain mean divides by the count, which is the same as giving every item a weight of 1. A weighted mean divides by the total weight, so an item carrying a weight of 40 counts forty times as much as one carrying a weight of 1.

Take the default set: values 90, 80, 70 with weights 0.5, 0.3, 0.2.

90 × 0.5 = 45 80 × 0.3 = 24 70 × 0.2 = 14 45 + 24 + 14 = 83 83 ÷ 1.0 = 83

The unweighted mean of 90, 80 and 70 is 80. The weighted average is 83, three points higher, because the highest value carries half the weight on its own.

Course grades where each part is worth a different percentage

This is the most common reason people need a weighted average. A syllabus almost never counts every assignment equally.

Example: a course graded out of four components

Homework is worth 15%, quizzes 20%, the midterm 25% and the final exam 40%. A student scores 100, 95, 80 and 65.

100 × 0.15 = 15 95 × 0.20 = 19 80 × 0.25 = 20 65 × 0.40 = 26 15 + 19 + 20 + 26 = 80 80 ÷ 1.00 = 80

The course grade is 80, not the 85 you get by averaging the four scores. The weak final exam counts for more than the perfect homework score, and it costs five points.

ComponentScoreWeightScore × weightShare of grade
Homework10015%15.015%
Quizzes9520%19.020%
Midterm8025%20.025%
Final exam6540%26.040%
Total100%80.0100%

You can enter the weights as 15, 20, 25, 40 or as 0.15, 0.2, 0.25, 0.4. Either way the total weight is what the sum of the products gets divided by, so both produce 80.

The same table answers the question students actually want: what do I need on the final? The first three components have already contributed 15 + 19 + 20 = 54 points. To finish on 85 you need 31 more points from a component worth 40, so you need 31 ÷ 0.40 = 77.5 on the final.

GPA with credit hours

A GPA is a weighted average where the weights are credit hours. A four-credit course moves your GPA four times as much as a one-credit seminar, which is why an easy A in a small class barely helps.

Example: one semester, four courses

Calculus A− (3.7) for 4 credits, English B (3.0) for 3 credits, Chemistry B+ (3.3) for 4 credits, Seminar A (4.0) for 1 credit.

3.7 × 4 = 14.8 3.0 × 3 = 9.0 3.3 × 4 = 13.2 4.0 × 1 = 4.0 total grade points = 41.0 total credits = 12 41.0 ÷ 12 = 3.42

The GPA is 3.42. Averaging the four grade points without weighting gives 3.5, because it treats the one-credit A as equal to the four-credit A−.

To combine semesters, keep using credits as the weights: multiply each semester’s GPA by the credits taken that semester, add the products, and divide by the total credits. Averaging the two GPAs directly only works if the credit loads were identical.

Weighted average cost of inventory or a stock position

Buy the same item at different prices and your average cost is weighted by quantity, not by how many times you bought.

Example: a position built in three purchases

100 shares at $42, then 50 shares at $55, then 25 shares at $38.

100 × 42 = 4,200 50 × 55 = 2,750 25 × 38 = 950 total cost = $7,900 total shares = 175 7,900 ÷ 175 = $45.14

The average cost per share is $45.14. The plain average of the three prices is $45.00, and the difference comes from the 50-share purchase at $55 counting twice as heavily as the 25-share purchase at $38.

Inventory works the same way under the weighted average cost method: total cost of goods available divided by total units available, which is exactly Σ(price × quantity) ÷ Σ(quantity). Enter prices as values and quantities as weights.

The pattern extends anywhere quantity varies. Blended interest rates weight each rate by the loan balance. A portfolio’s return weights each holding’s return by its dollar value. An average rating across products weights each product’s score by its number of reviews.

Weights do not have to add up to 1

There is no rule that weights must sum to 1, or to 100, or to anything in particular. The formula divides by whatever the weights actually total, so the scale takes care of itself.

values 80, 90 with weights 3 and 1 → (240 + 90) ÷ 4 = 82.5 values 80, 90 with weights 0.75, 0.25 → (60 + 22.5) ÷ 1 = 82.5 values 80, 90 with weights 75, 25 → (6,000 + 2,250) ÷ 100 = 82.5

All three describe the same mix and give the same answer. What matters is the ratio between the weights, not their size. Three gallons of water at 40°F mixed with one gallon at 80°F settles at (120 + 80) ÷ 4 = 50°F — the weights 3 and 1 need no conversion into percentages.

This is also why the result always moves toward the heaviest item. The weighted average is a balance point, and it sits nearer whichever side carries more weight. It can never fall outside the range of your values: with weights that are all positive, the answer is always between the smallest and the largest value, hitting an end only if all the weight sits on that one item.

Watch outAn item with a weight of 0 is included in the list but contributes nothing and does not change the answer. If every weight is 0, there is nothing to divide by and no average exists.

When every weight is equal, the weighted average collapses back into the plain mean — which is the figure the average calculator gives you.

Common mistakes

  • Values and weights out of order. The lists pair up position by position. A single missing entry near the top shifts every pair after it.
  • Dividing by the number of items. Divide by the total weight. With four components weighted 15, 20, 25 and 40, you divide by 100, not by 4.
  • Assuming the weights total 100 when they do not. If a syllabus lists parts adding to 90% because one assignment was dropped, the calculator divides by 90 and gives your grade on the work that counted.
  • Weighting by the wrong quantity. Average share cost is weighted by number of shares, not by number of trades. Average unit cost is weighted by units, not by invoices.
  • Averaging percentages that have different bases. A 50% rate from 4 attempts and a 90% rate from 100 attempts weight to 88.5%, not 70%. Convert with the percent to decimal calculator if your formula needs decimals.
  • Rounding thirds to 0.33 each. Three equal weights of 0.33 total 0.99, not 1. Use 1, 1, 1 instead and let the division handle it.
  • Forgetting that a zero score still carries its weight. A missed assignment worth 20% enters as a value of 0 with weight 20, not as an item you delete.
  • Using a weighted mean on badly skewed data. Weighting does not fix an outlier problem; the median calculator handles that case better.

Frequently asked questions

How do you calculate a weighted average?

Multiply each value by its weight, add up all the products, then divide by the total of the weights. In symbols, Σ(value × weight) ÷ Σ(weights). The only difference from a plain average is the final division: a plain mean divides by how many items you have, a weighted mean divides by how much weight they carry in total.

What is the weighted average of 90, 80 and 70 with weights 0.5, 0.3 and 0.2?

It is 83. The products are 90 × 0.5 = 45, 80 × 0.3 = 24 and 70 × 0.2 = 14, which add to 83. The weights total 1, so 83 ÷ 1 = 83. The unweighted mean of the same three numbers is 80; the weighted figure is higher because the 90 carries half the weight by itself.

Do the weights have to add up to 1 or 100?

No. The formula divides by whatever the weights actually total, so 3 and 1 works exactly like 0.75 and 0.25 or 75 and 25. Only the ratio between the weights matters. This is what lets you use raw credit hours, share counts or unit quantities as weights without converting anything to percentages first.

What is my grade if homework is 15%, quizzes 20%, the midterm 25% and the final 40%?

With scores of 100, 95, 80 and 65 the grade is 80. The contributions are 15 + 19 + 20 + 26 = 80 points out of 100. The plain average of those four scores is 85, so the weighting costs five points here: the strongest score sits on the lightest component and the weakest sits on the heaviest.

How do you work out GPA with credit hours?

Use grade points as the values and credit hours as the weights. For a 3.7 over 4 credits, 3.0 over 3, 3.3 over 4 and 4.0 over 1, the grade points come to 14.8 + 9 + 13.2 + 4 = 41 across 12 credits, so the GPA is 41 ÷ 12 = 3.42. Averaging the four grade points instead would give 3.5.

What is the average cost of shares bought at different prices?

Weight each price by the number of shares. Buying 100 at $42, 50 at $55 and 25 at $38 costs 4,200 + 2,750 + 950 = $7,900 for 175 shares, so the average cost is 7,900 ÷ 175 = $45.14 per share. Averaging the three prices gives $45.00, which understates the cost because the largest purchase was not the cheapest.

Why is the weighted average different from the plain average?

Because a plain average silently assumes every item counts the same. The weighted answer always leans toward the values carrying the most weight, so the two agree only when the weights are equal or when the values are identical. The size of the gap tells you how much the weighting is actually doing.

Can a weight be zero or negative?

A weight of zero is fine: the item stays in the list but contributes nothing. Negative weights are valid arithmetic but rarely mean anything, and they let the answer land outside the range of your values. If all the weights add to zero there is nothing to divide by, and the calculator tells you rather than returning a number.

Put this calculator on your own site (free)

Copy this into any page. The calculator stays up to date on its own, works on mobile, and carries a small credit link back here.

Preview it
Cite this page “Weighted Average Calculator”. Four Function Calculator, 6 September 2026.https://fourfunctioncalculator.com/weighted-average-calculator/
Shows the workingRuns entirely in your browser — nothing you type is sent anywhere.Last reviewed 6 September 2026