Track multiple stock purchases and instantly calculate your weighted average share cost (including optional fees).
Tip: Enter each buy separately. Leave a row blank if you do not need it.
What is an average share cost?
Your average share cost is the weighted average price you paid across all purchases of the same stock. This number helps you understand your true entry price and whether your position is currently in profit or loss.
If you bought shares at different prices over time, the average is not a simple midpoint. It must account for how many shares were bought in each order and any transaction fees.
The formula behind this calculator
The weighted average share cost formula is:
Average Cost = (Total Purchase Cost + Total Fees) / Total Shares
Step-by-step
- Multiply each purchase price by the number of shares in that order.
- Add optional fees or commissions for each order.
- Sum all shares from all purchases.
- Divide total invested amount by total shares.
Why investors use average cost
Average cost becomes especially useful if you invest over time instead of buying all at once. It gives a clear answer to: “At what price do I break even?”
Common use cases
- Dollar-cost averaging: You buy monthly and want one clean number for your position.
- Risk control: You compare current price to your average to evaluate position health.
- Exit planning: You estimate potential gain/loss before selling.
- Portfolio reviews: You track progress across multiple holdings.
Example calculation
Suppose you made three purchases:
- 10 shares at $100, fee $1
- 15 shares at $90, fee $1
- 20 shares at $80, fee $1
Total invested = (10×100 + 1) + (15×90 + 1) + (20×80 + 1) = $3,953
Total shares = 45
Average cost = $3,953 / 45 = $87.84 per share (rounded)
How to use this average share cost calculator
1) Enter each purchase lot
For each buy, fill in shares, price per share, and optional fee. Use “Add Purchase” to include more lots.
2) Optionally enter current market price
If you enter the current price, the calculator also shows market value and unrealized gain or loss.
3) Click calculate
You’ll instantly get total shares, total invested amount, average cost per share, and break-even price.
Mistakes to avoid
- Ignoring fees if your broker charges commissions.
- Using average cost across different tickers (calculate each stock separately).
- Confusing average cost with tax basis rules in your country.
- Forgetting that average cost does not guarantee future returns.
Important notes on taxes and strategy
This tool is for educational planning and quick estimates. Tax reporting methods vary by jurisdiction (FIFO, specific identification, average basis rules, and more). Always confirm with your broker statements and a qualified tax advisor.
From an investing perspective, average cost can improve discipline, but it should be paired with a broader plan: diversification, risk limits, and long-term goals.
Final thought
If you buy shares in multiple steps, your average share cost is one of the most useful numbers you can track. It gives clarity, helps reduce emotional decisions, and makes your next move more deliberate.