📉 DCA Calculator
Dollar Cost Averaging: add multiple buys at different prices and see your real average cost. Free, instant, visual.
Track your dollar-cost averaging strategy by adding multiple buy entries with their own price and quantity. The calculator computes total invested, total shares accumulated, and true average cost per share. Enter a market price to see unrealized profit or loss. A color-coded bar chart shows each purchase against your average: green buys below cost basis, red above.
📋 When to Use the DCA Calculator
Dollar-cost averaging (DCA) investors use this calculator to track their real average cost per share across multiple purchases at different prices — add each buy with its price and quantity, then compare against the current market price to see your profit or loss. It works for stocks, ETFs, cryptocurrencies, or any asset where you enter price and quantity. The bar chart color-codes each purchase (green below your average, red above) so you can see at a glance which buys were timed well. ⚠️ This tool calculates mathematical averages — it does not predict future prices or guarantee investment outcomes. Market conditions change; this is not financial advice.
⚙️ How the DCA Calculator Works
The calculator maintains a list of your buy transactions. The weighted average cost per share is computed as: avg = Σ(priceᵢ × quantityᵢ) / Σ(quantityᵢ) — total dollars invested divided by total shares accumulated. Profit/Loss is: P/L = (market price − avg cost) × total quantity. Results update instantly as you add or remove buys. The bar chart is rendered with Chart.js, where each bar's height represents quantity and the color reflects whether that purchase was below (green) or above (red) your average cost. The blue dashed reference line marks your average. All computation is client-side — no trading data is sent anywhere.
How to Use the DCA Calculator
- Enter the price and quantity of each investment purchase and click '+ Add Buy'.
- Add multiple buys at different price points to simulate your dollar-cost averaging strategy.
- View your total invested, average cost per share, and profit/loss at current market price.
- Use the chart to visualize your purchase distribution and cost basis.
Frequently Asked Questions
What is Dollar Cost Averaging (DCA)?
Dollar Cost Averaging is an investment strategy where you invest a fixed amount of money at regular intervals, regardless of the asset price. This reduces the impact of market volatility and often results in a lower average cost per share than lump-sum investing during volatile periods.
How is the average cost calculated?
The average cost is calculated by dividing the total amount invested by the total number of shares purchased across all your buy transactions. Each buy's contribution is weighted by the quantity purchased.
Can I use this for cryptocurrencies?
Yes, the DCA Calculator works for any asset where you track price and quantity — stocks, ETFs, cryptocurrencies, or commodities. The math is the same regardless of the asset type.
How does the P/L calculation work?
The Profit/Loss is calculated by comparing your current average cost to a current market price you enter. P/L = (Market Price - Average Cost) × Total Quantity. A positive value means you're in profit; negative means you're at a loss.