Skip to content
D DocNectar

Free Stock Average Cost Calculator

Calculate your average cost per share across multiple stock purchases.

100% Free No Signup Works on all devices

Built and fact-checked by the DocNectar team — see our editorial standards

Thanks for rating!

Key Features

Instant Calculation

Get accurate results in real time with our optimized algorithm.

Mobile Friendly

Fully responsive design. Works on all devices & screen sizes.

Privacy Focused

Your data stays on your device. We don't store any inputs.

100% Free

No hidden costs. This tool is completely free forever.

When you buy shares of the same stock at different prices over time, your true cost basis is a weighted average, not a simple average of the prices you paid — buying more shares at one price pulls the average toward that price more than a smaller purchase would.

This calculator finds your weighted average cost per share across up to five separate purchase lots, with a full step-by-step solution.

How it works

Enter the price and number of shares for each purchase lot (up to five). The calculator multiplies each lot's price by its share count, sums the total cost and total shares across all lots, then divides to find the weighted average cost per share.

  1. Enter lot 1 — price per share.
  2. Enter lot 1 — number of shares.
  3. Enter lot 2 — price per share (optional).
  4. Enter lot 2 — number of shares (optional).
  5. Enter lot 3 — price per share (optional).
  6. Enter lot 3 — number of shares (optional).
  7. Enter lot 4 — price per share (optional).
  8. Enter lot 4 — number of shares (optional).
  9. Enter lot 5 — price per share (optional).
  10. Enter lot 5 — number of shares (optional).
  11. Click Calculate to see your results.

Examples

Two purchases at different prices

Buying 10 shares at $100 and 5 shares at $90 gives a total cost of $1,450 across 15 shares, for an average cost of $96.67 per share.

Who should use it

  • Finding your true average cost basis after buying shares of the same stock at different times.
  • Understanding your actual breakeven price before deciding whether to sell.

Industry applications

  • Personal investing and portfolio tracking
  • Tax preparation and capital gains reporting

Advantages

  • Correctly weights each lot by its share count rather than simply averaging prices.
  • Includes a complete, formula-based step-by-step solution.

Limitations

  • Limited to five purchase lots — positions built from more than five separate purchases need to be combined manually first.

Common mistakes to avoid

  • Simply averaging the purchase prices without weighting by the number of shares in each lot, which gives an incorrect result whenever lot sizes differ.
  • Forgetting to include a lot (like a dividend reinvestment purchase) that also affects the true average cost.

Best practices

  • Include every purchase lot for the position, even small ones like dividend reinvestments, for an accurate average cost basis.

Tips

  • Dollar-cost averaging (investing a fixed amount on a regular schedule) naturally produces a lower average cost per share than investing the same total amount at a single high price — this calculator can help you see that effect across your own actual purchases.

Frequently asked questions

Yes, with no signup and no limit on how many calculations you run.
Because each purchase has a different number of shares — a larger purchase should count more toward the average than a smaller one, which is exactly what a weighted average (using total cost divided by total shares) accounts for.
Your average cost per share (cost basis) is used to calculate capital gains or losses when you eventually sell — knowing it helps you understand your true breakeven price and tax implications.
Yes — the same weighted average math applies to any asset purchased in multiple lots at different prices, not just stocks.

Get new calculators and guides in your inbox

No spam — just new tools like Stock Average Calculator and practical guides.

Favorites