Dollar-cost averaging calculator
Dollar-cost averaging means buying for the same amount of money at regular intervals, whatever the price. List the prices you paid (or might pay), and the calculator shows how many shares you end up with, the average cost per share, the value at the latest or current price and the gain.
Runs in your browser: nothing you enter is sent anywhere.
How to use it
- Enter the amount you invest each time, for example 100.
- List the price at each purchase in order: weekly, monthly or whatever your schedule is.
- Add a fee per purchase if your broker charges one.
- Optionally enter today’s price; otherwise the last price in the list is used.
How it works
Each purchase buys (amount − fee) ÷ price shares. Then:
- total invested = amount × number of purchases;
- average cost per share = total invested ÷ total shares;
- value now = total shares × current price;
- return = (value now − total invested) ÷ total invested × 100 %.
The tool also shows the plain average of the prices, so you can compare it with your average cost.
Worked example
You invest 100 four times, at prices 20, 25, 16 and 20, with no fee.
- Shares: 100 ÷ 20 + 100 ÷ 25 + 100 ÷ 16 + 100 ÷ 20 = 5 + 4 + 6.25 + 5 = 20.25.
- Invested: 4 × 100 = 400.00.
- Average cost: 400 ÷ 20.25 = 19.75, below the average of the prices, 20.25.
- Value at the last price, 20: 20.25 × 20 = 405.00, a gain of 5.00, or 1.25%.
The price ended where it started, yet the plan is ahead because the dip to 16 bought extra shares.
Tips
- Use the actual fill prices from your statements for a past plan; for a “what if”, try a falling, a rising and a flat series.
- Dividends, taxes and currency conversion are not included.
- If you invest different amounts each time, the stock average calculator, which takes shares and price per purchase, fits better.
Frequently asked questions
What is dollar-cost averaging?
Investing a fixed sum on a schedule, for example 100 every month, instead of one lump sum. When the price is low the same money buys more shares, when it is high it buys fewer.
Why is my average cost lower than the average price?
Because you bought more shares at the low prices. The average cost is the total invested divided by the shares, which without fees is the harmonic mean of the prices; that is never higher than their plain average, and equal only when every price is the same.
Does dollar-cost averaging beat investing all at once?
Not necessarily. In a market that mostly rises, a lump sum invested earlier is often ahead; averaging spreads out the timing risk. The calculator shows the arithmetic of your own prices, not a forecast.
How are fees counted?
The fee is taken from each purchase before buying, so fewer shares are bought, and it stays in the total invested. A fee of 2 on 100 buys shares for 98.
Can I use it for crypto or funds?
Yes. It works for anything bought for a set amount at a known price, including fractional shares and coins.