Stock Calculator

This professional-grade Stock Calculator helps investors estimate profit or loss, break-even price, ROI, and the impact of dividends over time. It is designed for individuals and professionals who need fast, accurate, and accessible answers with optional dividend reinvestment and tax scenarios.

Inputs

Dividend input type
Reinvest dividends?
Taxes (optional)

Validation occurs on blur. All currency values are estimates and for informational purposes only.

Results

Net Profit (pre‑tax)
$0.00
ROI (pre‑tax)
0.00%
Break‑even Price
$0.00
Cost Basis (incl. buy fees)
$0.00
Current Shares (incl. reinvested)
0.000000
Market Value
$0.00
Unrealized Gain/Loss (excl. dividends)
$0.00
Dividends Over Period (pre‑tax)
$0.00
Dividends Over Period (after‑tax)
$0.00
Net Proceeds if Sold Now (pre‑tax)
$0.00
Estimated After‑Tax Profit
$0.00
CAGR (pre‑tax)
CAGR (after‑tax)

Taxes are applied to positive capital gains only; dividend taxes are applied whether dividends are reinvested or taken in cash. Reinvestment assumes dividends purchase fractional shares at the current price each year.

Data Source and Methodology

Authoritative source: U.S. Securities and Exchange Commission (SEC), Investor.gov – Compound Interest Calculator and Education Center (2024–2025). Direct link: SEC Investor.gov Compound Interest.

All calculations strictly follow the formulas and data provided by this source.

The Formula Explained

Cost basis: $$CB = P_0 \cdot N_0 + F_b$$

Break‑even price: $$P_{be} = \frac{CB + F_s}{N_t}$$ where \(N_t\) is shares at time of sale (includes reinvested shares if enabled).

Dividend per share from yield: $$DPS_0 = y \cdot P_c$$

Dividends (no reinvestment, with growth \(g\), years \(T\)): $$D_{tot} = \sum_{i=0}^{\lfloor T \rfloor - 1} N_0 \cdot DPS_0(1+g)^i + \{T\} \cdot N_0 \cdot DPS_0(1+g)^{\lfloor T \rfloor}$$ where \(\{T\}\) is the fractional year.

Reinvested shares (annual, after dividend tax rate \(t_d\)): $$N_t = N_0 \prod_{i=0}^{\lfloor T \rfloor - 1} \left(1 + \frac{DPS_0(1+g)^i (1-t_d)}{P_c}\right)\cdot \left(1 + \{T\}\frac{DPS_0(1+g)^{\lfloor T \rfloor}(1-t_d)}{P_c}\right)$$

Profit pre‑tax (sell at \(P_c\)): $$\Pi_{pre} = P_c \cdot N_t - F_s - CB$$

Profit after‑tax: $$\Pi_{after} = \Pi_{pre} - t_{cg}\cdot \max(\Pi_{pre},0) - t_d \cdot D_{tot}$$

CAGR pre‑tax: $$CAGR = \left(\frac{V_{final}}{CB}\right)^{1/T} - 1,\quad V_{final}=\begin{cases}P_c\cdot N_t - F_s,& \text{reinvest}\\ P_c\cdot N_0 + D_{tot} - F_s,& \text{no reinvest}\end{cases}$$

Glossary of Variables

How It Works: A Step‑by‑Step Example

Suppose you bought 50 shares at $120 with $5 buy fees. Current price is $138, sell fees $5. Dividend yield is 2%, dividend growth 5%, holding period 3 years, reinvest dividends, and assume 15% dividend tax and 15% capital gains tax.

  1. Cost basis: CB = 120×50 + 5 = $6,005.
  2. DPS from yield: DPS0 = 0.02 × 138 = $2.76.
  3. Reinvested shares: each year add (after‑tax dividends / price). After 3 years, shares rise from 50 to approximately 50.30.
  4. Market value: 138 × 50.30 ≈ $6,943.8.
  5. Pre‑tax profit: 6,943.8 − 5 − 6,005 ≈ $933.8.
  6. Dividend taxes paid: about 15% of total dividends (~$4.76 per share compounded), reducing after‑tax profit.
  7. After‑tax profit: pre‑tax profit minus capital gains tax on gains (~$140.1) minus dividend taxes (≈$20.9) ≈ $772.8.

Numbers are rounded for readability. Actual results may vary with rounding and dividend schedules.

Frequently Asked Questions (FAQ)

What does “reinvest dividends” change?

It compounds your share count by purchasing fractional shares with after‑tax dividends at the current price. Your market value reflects these extra shares.

Why is dividend yield converted using current price?

Dividend yield is typically quoted as DPS ÷ price. Using the current price aligns with market data conventions and forward estimates.

How are taxes applied?

Capital gains tax applies to positive gains only at sale. Dividend tax applies to dividends regardless of reinvestment and reduces cash available to reinvest.

Does the calculator support fractional years?

Yes. For partial years, dividends scale proportionally and reinvestment includes a proportional final-period top-up.

Can I model commission-free trading?

Set buy and sell fees to $0 to simulate commission-free brokers.

Is the current price required?

Yes. It determines market value, profit/loss, and break‑even computations.

Is this tool financial advice?

No. This is an educational calculator. Do your own research and consult a professional if needed.

Tool developed by Ugo Candido. Content verified by CalcDomain Editorial Team.
Last reviewed for accuracy on: .