Stock Average Calculator
Find your true weighted average cost per share.
How This Tool Works
Operation: The Stock Average Price Calculator computes the weighted average purchase price of a stock when you have bought the same stock at different prices on different dates. The formula is:
Average Price = Total Cost / Total Shares
Where Total Cost = Σ(Quantity × Price) for each buy transaction, and Total Shares = Σ(Quantity) for all buy transactions.
The calculator supports multiple transactions — you can add any number of buy entries with different quantities and prices. The tool calculates:
- Weighted Average Buy Price — the blended cost basis
- Total Investment — sum of all money spent
- Current Market Value — total shares × current market price (if provided)
- Unrealised P&L — current value minus total investment (if current price is entered)
- Return Percentage — (current value / total investment − 1) × 100
All arithmetic is performed client-side using JavaScript's Number type for sub-millisecond computation.
Key Benefits of Using the Stock Average Calculator
- Complete confidentiality: Your trading history — individual transactions, quantities, and prices — stays entirely on your device. This is essential for investors who do not want their portfolio data tracked, stored, or potentially exposed by a server-side tool.
- Unlimited transaction entries: Add as many buy transactions as needed, regardless of whether you've accumulated a position over 5 trades or 50 trades over several years. Each new entry updates the blended average instantly.
- Real-time P&L visibility: Entering the current market price immediately shows unrealised profit or loss across your entire position — useful for deciding whether to hold, add more, or exit a position.
Practical Real-World Use Cases
- Long-term investors tracking cost basis: An investor who bought 100 shares of a stock at ₹1,200, then another 50 at ₹950 during a dip, and another 75 at ₹1,050 can instantly compute the blended average price and total investment without manual spreadsheet calculations.
- Traders evaluating avg-down strategies: A trader considering averaging down on a losing position can add hypothetical buy entries to see how much additional capital is needed to reach a target average price before committing real money.
- Portfolio managers consolidating reports: An advisor managing multiple buy executions for a client across different brokerage accounts can aggregate all transactions into one view to determine the true cost basis.
Frequently Asked Questions (FAQ)
Does this account for brokerage fees and taxes?
No. The calculator uses raw transaction prices only. To factor costs, add an estimated per-transaction cost (brokerage + STT + GST) to each buy price before entering it. For precision, use your brokerage's actual cost statement.
How does this handle stock splits and bonuses?
For stock splits (e.g., 2:1), multiply quantity by the split ratio (2×) and divide buy price by the ratio. For bonus shares (e.g., 1:1), add the bonus quantity at zero cost. The average price adjusts automatically.
Can I use this for intraday trades?
Yes, but note that the calculator treats all entries as delivery-based (long-term) buys. Intraday trades squared off on the same day do not add to your delivery position. Use this only for holdings carried overnight.