How to Calculate Weighted Average
Use weights when every data point should not count equally—grades by credit hours, portfolio cost basis by shares, or any ratio where importance differs.
How to Calculate Weighted Average
Updated May 2026 · ~8 min read
A weighted average combines values using explicitly matched weights. The result is meaningful only when units, timing, and population are compatible. Nonnegative weights place the result within the observed range; negative weights require a different interpretation.
When you need a weighted average
- Portfolio cost basis: you bought the same symbol at different prices and share counts—your true average cost per share is weighted by how many shares you hold at each price.
- GPA and grades: a 4-credit course should move your average more than a 1-credit lab; credits are the weights.
- Survey or blended metrics: combine scores when each component has a different importance (e.g. 60% exam, 30% project, 10% participation).
The formula
Weighted average = Σ(wi×xi) ÷ Σwi, with nonzero total weight
Weights need not total 1 or 100 because the formula normalizes by their sum, but each weight must match its value.
A normalized-weight example
Do not average percentages or rates with incompatible bases or periods.
Common mistakes
- Dividing by the number of rows instead of total weight.
- Mismatching weights and values.
- Mixing units or periods.
- Ignoring zero or negative total weight.
Try the calculator
Use the interactive calculator to plug in your numbers and see results instantly—without redoing the math by hand.
Open weighted average calculator →FAQ
Must weights sum to 100%?
No, the formula normalizes them.
Can weights be negative?
Some advanced models allow it, but interpretation changes.
Should the result lie within the range?
With nonnegative weights, yes.
Related calculators
Educational Disclaimer
This article is for educational and informational purposes only and should not be considered investment, financial, tax, or legal advice. Market information may change over time, and readers should verify important details independently before making financial decisions.