CodePackr Finance / Investments / Stock Average Calculator

Stock Average Calculator

Compute weighted average buy price after multiple purchases of the same stock.

Client-Side Execution & Privacy Guarantee

Calculations run locally in your web browser. The amounts, rates, and other figures you enter are not sent to our servers. This calculator is for educational estimates only and is not personalized financial advice.

Investors rarely buy their entire position in a stock all at once. You might buy in tranches to spread risk, or buy more when a stock you believe in drops in price. Tracking multiple purchases at different prices and quantities can get confusing. The Codepackr Finance Stock Average Calculator instantly computes your weighted average buy price and total invested capital, helping you understand exactly where your portfolio stands.

Like all Codepackr tools, this calculator runs entirely in your browser without uploading your financial data to external servers. The results are mathematical estimates based on the prices and quantities you input. Please note that this tool does not factor in brokerage, STT, or DP charges, which will slightly increase your true break-even price. This is an educational tool and does not constitute investment advice. Always review your broker's platform for official portfolio metrics. This content is for informational purposes only and is not financial advice.

The Math Behind Averaging

A simple average of your purchase prices is mathematically incorrect. You must calculate a weighted average, which gives more weight to the transactions where you bought a larger number of shares.

The formula is simple: (Total Capital Invested across all trades) divided by (Total Number of Shares held). This gives you the exact price the stock needs to reach for your position to break even.

Averaging Down vs. Averaging Up

Averaging down involves buying more shares when the price drops, lowering your overall break-even point. While popular, it carries the risk of throwing good money after bad if the company's fundamentals have permanently deteriorated.

Averaging up means buying more as the stock price rises, confirming an upward trend. While this increases your average cost, momentum investors prefer it as it aligns with buying winning assets.

Avoiding the Value Trap

A common mistake retail investors make is blindly averaging down a falling stock just to make their portfolio screen look less red. This often leads to over-allocation in a single risky asset.

Before using an averaging strategy, ensure you have set a strict maximum allocation limit (e.g., never letting one stock exceed 5% of your total portfolio) regardless of how tempting the lower price looks.

When to use this calculator

  • Planning to buy the dip and wanting to see how much your average price will drop.
  • Consolidating shares bought through direct equity SIPs over many months.
  • Calculating the break-even point for a stock you have accumulated in tranches.
  • Deciding exact position sizing before executing a secondary purchase.

How to use the Stock Average Calculator

  1. Enter the purchase price and quantity for your first stock transaction.
  2. Enter the purchase price and quantity for your second transaction.
  3. Click 'Add Row' to include as many historical purchases as necessary.
  4. Click calculate to instantly see your total shares, total capital invested, and new average price.
  5. Use this target average price to set limit orders or stop-loss triggers in your trading terminal.

Worked examples

Simple Averaging Down

Input

Trade 1: 100 shares @ INR 50, Trade 2: 100 shares @ INR 40

Output

Total Shares: 200, Total Invested: INR 9,000, Average Price: INR 45

Because the quantities are equal, the weighted average is exactly in the middle of the two prices.

Heavy Weighting

Input

Trade 1: 50 shares @ INR 200, Trade 2: 150 shares @ INR 100

Output

Total Shares: 200, Total Invested: INR 25,000, Average Price: INR 125

Because you bought 3x more shares at the lower price, the average price is pulled much closer to INR 100.

Common mistakes and tips

  • Remember that averaging down increases your total capital at risk. Ensure you are comfortable with the new total investment amount.
  • For tax purposes, Indian tax law uses the First-In-First-Out (FIFO) method, not your average price, to calculate capital gains when you sell partially.
  • Your true break-even price is slightly higher than the average price because of brokerage and statutory taxes.
  • Don't 'catch a falling knife'. Ensure the underlying business is sound before throwing more capital into a dropping stock.

Frequently asked questions

Does my broker use average price for tax calculations?

No, for income tax purposes in India, the First-In-First-Out (FIFO) method is strictly used. Average price is only for your personal portfolio tracking.

Is it better to average down or average up?

It depends on your strategy. Value investors tend to average down when stocks fall below intrinsic value, while trend followers average up to ride momentum.

Does this calculator include brokerage fees?

No, this calculator only computes the weighted average of the share price. You can use our Brokerage Calculator to estimate additional fees.

How many trades can I average together?

You can add as many rows as you need to calculate the average across dozens of historical SIPs or ad-hoc purchases.

Can I use this for crypto or mutual funds?

Yes, the math for weighted averages is universal. You can use this tool to calculate average buy prices for crypto tokens, ETFs, or mutual fund units.

Related Investments Calculators

  • SIP Calculator — Calculate Systematic Investment Plan (SIP) returns, wealth accumulation, and annual step-up compounding.
  • Lumpsum Investment Calculator — Compute compound growth, maturity wealth, and inflation-adjusted real purchasing power for one-time investments.
  • CAGR Calculator (Compound Annual Growth) — Calculate Compound Annual Growth Rate, annualized geometric returns, capital multiples, and holding trajectories.
  • ROI Calculator (Return on Investment) — Calculate net return on investment, annualized holding period return, and capital multiples after fees.
  • Compound Interest Calculator — Calculate compound interest growth with periodic deposits, flexible compounding frequencies, and APY rates.
  • FD Calculator (Fixed Deposit) — Calculate fixed deposit maturity with monthly/quarterly/yearly compounding, senior citizen rates, pre/post-tax returns, TDS and inflation-adjusted real value.
  • RD Calculator (Recurring Deposit) — Project recurring deposit maturity from monthly deposits with quarterly compounding, optional annual step-up and senior citizen rates.
  • SWP Calculator (Systematic Withdrawal) — Project corpus drawdown under systematic monthly withdrawals with optional inflation step-up, survival years and year-wise balance.

See all Investments calculators →