Dollar-Cost Averaging Calculator
Investing $500.00 at each of 12 prices (from $100.00 down to $78.00 and back up to $115.00) gives Average cost $95.5438 per share vs average price $96.8333. $6,000.00 invested over 12 periods buys 62.7984 shares, worth $7,221.82 at the last price (+$1,221.82, +20.36%). The same $6,000.00 invested at the first price ends at $6,900.00 (+15.00%). Spreading a fixed amount over time always buys at an average cost no higher than the average price, because the same dollars buy more shares when the price is low. Whether that beats a lump sum depends on what prices do next. This is an estimate from the prices you enter, not investment advice.
Updated By ponderloop editorial · How we checkRuns in your browser: nothing you enter is uploadedHow this tool works
1. Actual prices: average cost vs lump sum
Average cost $95.5438 per share vs average price $96.8333
$6,000.00 invested over 12 periods buys 62.7984 shares, worth $7,221.82 at the last price (+$1,221.82, +20.36%). The same $6,000.00 invested at the first price ends at $6,900.00 (+15.00%).
- Periods
- 12
- Invested per period
- $500.00
- Total invested
- $6,000.00
- Shares bought
- 62.7984
- Average cost per share (harmonic mean)
- $95.5438
- Average price (arithmetic mean)
- $96.8333
- Average cost below average price
- $1.2895 (1.33%)
- First price
- $100.00
- Last price
- $115.00
- Value at last price
- $7,221.82
- Gain or loss
- +$1,221.82 (+20.36%)
- Lump sum at first price: value
- $6,900.00
- Lump sum: gain or loss
- +$900.00 (+15.00%)
- Dollar-cost averaging minus lump sum
- +$321.82
The working
- Each period buys amount ÷ price shares. Period 1: $500.00 ÷ $100.00 = 5.0000 shares. Adding all 12 periods gives 62.7984 shares for $6,000.00.
- Average cost = total invested ÷ total shares = $6,000.00 ÷ 62.7984 = $95.5438 per share.
- That is the harmonic mean of the prices: 12 ÷ (1/p1 + 1/p2 + … + 1/p12) = 12 ÷ 0.12559685 = $95.5438.
- The harmonic mean is never above the arithmetic mean of the same numbers ($96.8333), and they match only when every price is the same. So the average cost is never above the average price: a fixed amount buys more shares when the price is low.
- Value at the last price = 62.7984 × $115.00 = $7,221.82; gain = $7,221.82 − $6,000.00 = +$1,221.82 (+20.36%).
- Lump sum: $6,000.00 ÷ $100.00 buys 60.0000 shares on day one; at $115.00 they are worth $6,900.00 (+15.00%).
Period by period
| Period | Price | Shares bought | Total shares | Total invested | Average cost so far | Value at this price |
|---|---|---|---|---|---|---|
| 1 | $100.00 | 5.0000 | 5.0000 | $500.00 | $100.0000 | $500.00 |
| 2 | $92.00 | 5.4348 | 10.4348 | $1,000.00 | $95.8333 | $960.00 |
| 3 | $85.00 | 5.8824 | 16.3171 | $1,500.00 | $91.9279 | $1,386.96 |
| 4 | $78.00 | 6.4103 | 22.7274 | $2,000.00 | $87.9995 | $1,772.74 |
| 5 | $84.00 | 5.9524 | 28.6798 | $2,500.00 | $87.1694 | $2,409.10 |
| 6 | $90.00 | 5.5556 | 34.2353 | $3,000.00 | $87.6288 | $3,081.18 |
| 7 | $95.00 | 5.2632 | 39.4985 | $3,500.00 | $88.6110 | $3,752.36 |
| 8 | $99.00 | 5.0505 | 44.5490 | $4,000.00 | $89.7888 | $4,410.35 |
| 9 | $104.00 | 4.8077 | 49.3567 | $4,500.00 | $91.1731 | $5,133.10 |
| 10 | $108.00 | 4.6296 | 53.9863 | $5,000.00 | $92.6161 | $5,830.52 |
| 11 | $112.00 | 4.4643 | 58.4506 | $5,500.00 | $94.0966 | $6,546.47 |
| 12 | $115.00 | 4.3478 | 62.7984 | $6,000.00 | $95.5438 | $7,221.82 |
| All 12 | Mean $96.8333 | 62.7984 | 62.7984 | $6,000.00 | $95.5438 | $7,221.82 |
The last row totals all 12 periods.
2. Projection: monthly investing at an assumed constant return
A hypothetical illustration, not a forecast: real returns are not constant.
Future value $156,278.00 after 20 years
Hypothetical illustration, not a forecast: contributing $300.00 a month for 240 months puts in $72,000.00, and an assumed constant 7% a year adds +$84,278.00 of growth.
- Monthly contribution
- $300.00
- Years (months)
- 20 (240)
- Assumed annual return (constant)
- 7%
- Total contributed
- $72,000.00
- Growth
- +$84,278.00
- Future value
- $156,278.00
- Growth as a share of future value
- 53.93%
- Same total as a lump sum on day one
- $290,789.20
- Lump sum minus monthly contributions
- +$134,511.20
The working
- Monthly rate i = 7% ÷ 12 = 0.5833% (compounded monthly, contribution at the end of each month).
- Future value = contribution × ((1 + i)^240 − 1) ÷ i = $156,278.00.
- Total contributed = $300.00 × 240 = $72,000.00; growth = $156,278.00 − $72,000.00 = +$84,278.00.
- The same $72,000.00 invested on day one at the same constant return would grow to $290,789.20. With a constant return, money invested earlier has longer to grow; real returns are not constant, so this says nothing about which approach will do better.
- The return is held constant for illustration. Real investments rise and fall, and fees and taxes are left out.
Month by month
| Month | Contribution | Growth this month | Total contributed | Balance |
|---|---|---|---|---|
| 1 | $300.00 | $0.00 | $300.00 | $300.00 |
| 2 | $300.00 | $1.75 | $600.00 | $601.75 |
| 3 | $300.00 | $3.51 | $900.00 | $905.26 |
| 4 | $300.00 | $5.28 | $1,200.00 | $1,210.54 |
| 5 | $300.00 | $7.06 | $1,500.00 | $1,517.60 |
| 6 | $300.00 | $8.86 | $1,800.00 | $1,826.46 |
| 7 | $300.00 | $10.65 | $2,100.00 | $2,137.11 |
| 8 | $300.00 | $12.47 | $2,400.00 | $2,449.58 |
| 9 | $300.00 | $14.29 | $2,700.00 | $2,763.87 |
| 10 | $300.00 | $16.12 | $3,000.00 | $3,079.99 |
| 11 | $300.00 | $17.96 | $3,300.00 | $3,397.95 |
| 12 | $300.00 | $19.83 | $3,600.00 | $3,717.78 |
| 13 | $300.00 | $21.68 | $3,900.00 | $4,039.46 |
| 14 | $300.00 | $23.57 | $4,200.00 | $4,363.03 |
| 15 | $300.00 | $25.45 | $4,500.00 | $4,688.48 |
| 16 | $300.00 | $27.35 | $4,800.00 | $5,015.83 |
| 17 | $300.00 | $29.26 | $5,100.00 | $5,345.09 |
| 18 | $300.00 | $31.18 | $5,400.00 | $5,676.27 |
| 19 | $300.00 | $33.11 | $5,700.00 | $6,009.38 |
| 20 | $300.00 | $35.05 | $6,000.00 | $6,344.43 |
| 21 | $300.00 | $37.01 | $6,300.00 | $6,681.44 |
| 22 | $300.00 | $38.98 | $6,600.00 | $7,020.42 |
| 23 | $300.00 | $40.95 | $6,900.00 | $7,361.37 |
| 24 | $300.00 | $42.94 | $7,200.00 | $7,704.31 |
| All 240 | $72,000.00 | +$84,278.00 | $72,000.00 | $156,278.00 |
The first 24 of 240 months are shown; the last row totals all 240. The CSV has every month.
Dollar-cost averaging vs a lump sum on different price paths
| Price path | Average cost | Average price | DCA gain or loss | Lump-sum gain or loss | DCA minus lump sum |
|---|---|---|---|---|---|
| Falls, then recovers (the example) | $95.5438 | $96.8333 | +$1,221.82 (+20.36%) | +$900.00 (+15.00%) | +$321.82 |
| Rises steadily | $107.2554 | $107.5000 | +$216.62 (+7.22%) | +$450.00 (+15.00%) | −$233.38 |
| Falls steadily | $86.6608 | $87.5000 | −$403.67 (−13.46%) | −$750.00 (−25.00%) | +$346.33 |
| Zigzags and ends where it began | $97.2973 | $100.0000 | +$83.33 (+2.78%) | $0.00 (0.00%) | +$83.33 |
| Flat | $100.0000 | $100.0000 | $0.00 (0.00%) | $0.00 (0.00%) | $0.00 |
Projection: what the assumed return does
| Assumed annual return | Total contributed | Growth | Future value | Same total as a lump sum on day one |
|---|---|---|---|---|
| 0% | $72,000.00 | $0.00 | $72,000.00 | $72,000.00 |
| 4% | $72,000.00 | +$38,032.39 | $110,032.39 | $160,025.91 |
| 7% | $72,000.00 | +$84,278.00 | $156,278.00 | $290,789.20 |
| 10% | $72,000.00 | +$155,810.65 | $227,810.65 | $527,621.30 |
How to use the Dollar-Cost Averaging Calculator
- Enter the price for each period. Type or paste one price per period, one per line (for example the month-end price of a fund). The example has 12 prices. Spaces, semicolons and commas also separate prices; to use a thousands comma, add a $ sign or a decimal point (for example $1,250 or 1,250.50).
- Enter the amount you invest each period. Type the fixed amount, for example $500.00. Each period buys that amount divided by that period’s price in shares.
- Compare the average cost with the average price and the lump sum. Read the headline (Average cost $95.5438 per share vs average price $96.8333), the value at the last price and the lump-sum comparison, then check the period-by-period table.
- Try the projection. For a what-if, enter a monthly contribution, a number of years and an assumed constant annual return. The example gives future value $156,278.00 after 20 years. It is an illustration, not a forecast.
Frequently asked questions
- What is dollar-cost averaging?
- Dollar-cost averaging means investing the same amount at regular intervals, whatever the price. A fixed amount buys more shares when the price is low and fewer when it is high. In the example, $500.00 a period over 12 periods buys 62.7984 shares.
- Why is my average cost lower than the average price?
- Your average cost is total invested divided by total shares, which works out to the harmonic mean of the prices. The harmonic mean is never above the ordinary (arithmetic) average, and they are equal only when every price is the same. With two prices, $50 and $100, and $500 each time you buy 10 shares and 5 shares: $1,000.00 buys 15 shares, an average cost of $66.6667, while the average of the two prices is $75.0000.
- Is dollar-cost averaging better than investing a lump sum?
- It depends on the prices that follow, which nobody knows in advance. If prices dip first and then recover, as in the example, averaging in finished +$321.82 against the lump sum. If prices rise steadily, the lump sum is ahead (averaging in finished −$233.38 in the steady-rise table row). On a zigzag that ends where it began, the difference is +$83.33. When prices tend to rise over time, money invested sooner has longer to grow, which favours a lump sum on average; but that is a tendency, not a guarantee. Spreading the money out lowers the chance of putting everything in just before a fall, at the price of often being invested for less time. That is a trade-off between expected growth and regret, not a rule.
- Does the calculator compare against a lump sum fairly?
- It puts the same total ($6,000.00 in the example) into the investment at the first price you entered and values it at the last price. That assumes the lump sum is available on day one, which is the case for money you already hold. If you only earn the money over time, there is no lump sum to compare against, and regular investing is simply how you invest.
- How is the projection calculated?
- It assumes a constant annual return, compounded monthly, with each contribution made at the end of its month. The future value is the contribution times ((1 + i)^n − 1) ÷ i, where i is the annual return divided by 12 and n is the number of months. For $300.00 a month for 20 years at 7% that is $156,278.00, of which $72,000.00 is your own money and $84,278.00 is growth.
- Is the projection a forecast of what I will earn?
- No. It holds the return constant to show how contributions, time and compounding add up. Real investments rise and fall, can lose money, and the order of good and bad years changes the outcome. At 0% the same contributions end at $72,000.00; at 10% they end at $227,810.65. Use it to compare plans, not to predict a result. Fees, taxes and inflation are not included.
- What prices can I enter?
- Up to 240 prices (20 years of monthly prices), each above zero with at most four decimal places and no more than $1,000,000. Fractional shares are assumed. If your broker only sells whole shares, the leftover cash is not counted here, so the real average cost will differ slightly. The page shows the first 24 periods and a totals row; the CSV download has every period.
- Does it include fees, taxes or dividends?
- No. Prices are treated as the price you pay, with no trading fees, bid-ask spread, taxes, or dividends. Fees and taxes lower real results, and reinvested dividends raise them.
- Is anything I type sent to a server?
- No. Your monthly amount, number of years and assumed return are worked through in your browser to get the future value, and none of it is uploaded or stored.
How it works
Actual prices: each period buys amount ÷ price shares. Total shares are the sum over all periods, the average cost per share is total invested ÷ total shares (the harmonic mean of the prices), and the value is total shares times the last price. The lump sum invests the same total at the first price and is valued at the last price. In the example, 12 periods at $500.00 buy 62.7984 shares at an average cost of $95.5438. Projection: a constant annual return compounded monthly with a contribution at the end of each month (the future value of an ordinary annuity). Money is kept in whole cents and every sum is exact; results are rounded half up once, for display.
Sources
- Hardy, Littlewood and Pólya, Inequalities, Cambridge University Press: the theory of means (the harmonic mean never exceeds the arithmetic mean)
- Kellison, The Theory of Interest, McGraw-Hill: annuities-certain (future value of an ordinary annuity)
More free tools
- Annuity CalculatorFixed annuity maths: what a lump sum pays each month, how long a balance lasts, the future value of deposits, or the rate needed. With a schedule and CSV.
- Stock Profit CalculatorStock profit or loss, return %, break-even sell price and average cost per share, with commissions and dividends. Runs in your browser.
- FIRE CalculatorYour FIRE number (spending ÷ withdrawal rate), the years to reach it, a year-by-year table, a rate sensitivity grid and your Coast FIRE number.
- Emergency Fund CalculatorWork out how much to keep in an emergency fund: months of essential expenses, the gap to your goal and how long it takes to save it.
- Compound Interest CalculatorFuture value with compound interest: initial deposit, rate, compounding frequency, optional monthly or yearly contributions, APY and a year-by-year table.
- ROI CalculatorReturn on investment from amount invested and returned: ROI %, dollar gain and annualized ROI (CAGR) from years or dates, with optional fees and income.
More: Saving and investingAll money & costsAll toolsHome & DIY calculators