---
title: "DCA vs Lump Sum: 155 Years of S&P 500 Historical Data"
description: "DCA vs lump sum investing: 150 years of S&P 500 data (1871-2026) show that the month you invest a lump sum matters less than you think -- but timing risk is real. Full methodology, dataset, and CSV downloads."
canonical_url: https://trendshare.org/how-to-invest/dca-vs-lump-sum-historical-data
markdown_url: https://trendshare.org/ai/dca-vs-lump-sum-historical-data.md
published: 2026-04-28
last_updated: 2026-05-24
content_license: https://trendshare.org/about/disclaimer
---
# DCA vs Lump Sum: 155 Years of S&P 500 Historical Data

Source: https://trendshare.org/how-to-invest/dca-vs-lump-sum-historical-data
Updated: 2026-05-24
Does dollar cost averaging actually beat investing a lump sum? We ran a
systematic backtest against 155 years of S&P 500 monthly data to find out.
The short answer: **lump sum and DCA produce nearly identical long-run
returns, but the timing of your lump sum purchase creates significant variation
in outcomes** -- and DCA hedges that risk reliably.

This page presents the full data, methodology, and downloadable results so
you can verify or extend the analysis yourself.

## What We Tested

We used Robert J. Shiller's S&P 500 dataset (Yale University,
[shillerdata.com](https://shillerdata.com)), which
provides real (inflation-adjusted) total return prices from January 1871 through
April 2026 -- 1,864 months of data. Using real total return prices means the
results account for both dividends and inflation, giving a true picture of
purchasing power.

For every rolling window of 1, 3, 5, 10, 20, and 30 years we simulated
investing $12,000 total in two ways:

  - **DCA:** $1,000 per month for 12 months, then hold to end of window.

  - **Lump sum (12 variants):** Invest all $12,000 in a single month. We tested all 12 possible entry months within the first year to capture timing variance -- investing in January vs. February vs. March, and so on.

For each window we computed: the DCA final value, the best-timed lump sum,
the worst-timed lump sum, and the average across all 12 timing variants.

## Key Findings

<table>
<thead>
<tr>
  <th>Window</th>
  <th>Windows Tested</th>
  <th>Lump Sum Timing Win %</th>
  <th>DCA Beats Median Lump %</th>
  <th>Avg Timing Spread</th>
  <th>Avg Annual Return</th>
</tr>
</thead>
<tbody>
<tr><td>1 year</td><td>1,852</td><td>47.8%</td><td>76.2%</td><td>$2,524</td><td>4.6%</td></tr>
<tr><td>3 years</td><td>1,828</td><td>47.8%</td><td>76.0%</td><td>$2,971</td><td>6.4%</td></tr>
<tr><td>5 years</td><td>1,804</td><td>47.8%</td><td>76.3%</td><td>$3,513</td><td>6.6%</td></tr>
<tr><td>10 years</td><td>1,744</td><td>47.8%</td><td>76.1%</td><td>$5,007</td><td>6.7%</td></tr>
<tr><td>20 years</td><td>1,624</td><td>47.9%</td><td>75.6%</td><td>$9,837</td><td>6.5%</td></tr>
<tr><td>30 years</td><td>1,504</td><td>48.0%</td><td>75.2%</td><td>$19,697</td><td>6.6%</td></tr>
</tbody>
</table>

**Lump Sum Timing Win %**: Of all 12 possible lump sum entry
months tested across all windows, roughly 47.8% produced a higher final value
than DCA. This is close to random -- in a rising market, the month you happen
to invest matters almost as much as the coin flip.

**DCA Beats Median Lump %**: In about 76% of all historical
windows, DCA outperformed the median lump sum timing outcome. In other words,
the typical investor picking a random month to deploy a lump sum did worse than
DCA three quarters of the time.

**Avg Timing Spread**: This is the average dollar difference
between the best-timed and worst-timed lump sum entry within each window. Over
10 years, getting unlucky with timing could cost you $5,007 out of a $12,000
investment -- a 42% gap -- purely due to which month you happened to invest.

## What This Means for Investors

Lump sum and DCA produce equivalent average returns over long periods -- the
annual return numbers are nearly identical because the market's long-run
trajectory dominates short-run timing effects. What differs is *variance*.
The investor who invests a lump sum in the wrong month faces a meaningfully
worse outcome than the investor who spreads the same amount over 12 months.

DCA's hedging value is most visible in the median comparison: because DCA
captures prices across 12 months, it is unlikely to capture the worst possible
month, and it is also unlikely to capture the best. For the majority of
historical windows, this averaging lands above the typical (median) single-month
outcome.

This supports a practical conclusion: **if you have a lump sum and
don't know which month to invest it, DCA over 12 months is a reasonable hedge
with no long-run return cost.** If you're investing from regular income
(paycheck), DCA is simply how investing works in practice.

## 10-Year Rolling Window Chart

The chart below shows the 10-year rolling window results from 1871 to 2016.
Each point represents a starting month; the shaded band shows the range between
the best and worst lump sum timing for that window. The DCA line runs through
the middle of the band in the vast majority of cases.

  <canvas id="dca-backtest-chart"></canvas>

## Download the Data

Both files are comma-separated UTF-8 text. Dollar amounts represent final
portfolio value starting from $12,000 invested. Annual returns are real
(inflation-adjusted).

  - **Summary by window length** -- one row per holding period (1, 3, 5, 10, 20, 30 years): [dca_backtest_summary.csv](/data/dca_backtest_summary.csv)  (columns: window_years, total_windows, lump_any_timing_wins_pct, dca_beats_median_pct, avg_timing_spread_usd, avg_lump_annual_return, avg_dca_annual_return)

  - **Full 10-year rolling series** -- one row per starting month from 1871 to 2016: [dca_backtest_10yr.csv](/data/dca_backtest_10yr.csv)  (columns: start_month, end_month, dca_final_usd, lump_best_timing_usd, lump_worst_timing_usd, lump_avg_timing_usd)

## Methodology and Algorithm

The full source code for the backtest is available for inspection and
reproduction. Below is the complete algorithm description.

### Data Source

Shiller S&P 500 monthly data from
[shillerdata.com](https://shillerdata.com).
Column used: *Real Total Return Price* (column 9 of the "Data" worksheet
in the downloadable Excel file). This series compounds dividends and adjusts
for CPI inflation, so all results represent real purchasing power gains, not
nominal returns.

### Simulation Setup

Total investment: $12,000. DCA: $1,000/month for 12 consecutive months,
each tranche held to the end of the window. Lump sum: $12,000 invested in a
single month. Rather than assume any particular entry month, we tested all 12
possible months within the DCA contribution window (month 0 through month 11)
and kept all 12 outcomes separately.

For each window starting at month *i* with holding period
*H* months:

`DCA final value = sum over m in [0..11] of:
    $1,000 * (price[i + H] / price[i + m])

Lump sum final value (variant k) =
    $12,000 * (price[i + H] / price[i + k])
    for k in [0..11]`</pre>

<p>The ratio price[end] / price[buy] gives total return (including reinvested
dividends, inflation-adjusted) from purchase to end of window.

### Reported Statistics

  - **lump_any_timing_wins_pct**: Fraction of all (window, timing) pairs where lump sum beat DCA. Denominator: windows × 12. Across all window lengths this is consistently ~47.8%, near random.

  - **dca_beats_median_pct**: Fraction of windows where DCA final value ≥ the lower median of the 12 lump sum variants (6th of 12 when sorted ascending). This is ~76% across all window lengths.

  - **avg_timing_spread_usd**: Average of (lump_max − lump_min) across all windows. Measures the dollar cost of bad timing.

  - **avg_annual_return**: Geometric mean of (final / 12000)^(1/years) − 1, averaged across all windows. Nearly identical for DCA and lump sum because the same market returns drive both.

### Limitations

  - The simulation uses a fixed $12,000 / $1,000-per-month amount. Results scale linearly with investment size.

  - Transaction costs, taxes, and bid/ask spreads are not modeled. Modern zero-commission brokers with fractional shares make the DCA cost negligible, but this was not always true historically.

  - The Shiller data uses month-end closing prices. Real investors may buy intramonth. This creates minor variance not captured here.

  - Results are for the U.S. S&P 500. International markets have different return and volatility profiles; the relative DCA/lump sum relationship may differ.

### Source Code

The backtest is implemented in Perl. The script reads the Shiller XLS,
iterates over all rolling windows, computes DCA and lump sum values per the
formulas above, and writes `data/dca_backtest_results.json`.
A second script reads that JSON and produces the CSV files.

To reproduce: download the Shiller data Excel file to
`data/shiller_sp500.xls`, then run:

`perl bin/run_dca_backtest.pl
perl bin/generate_dca_csvs.pl`</pre>

<p>The algorithm matches the formulas described above exactly, with no
adjustments, smoothing, or cherry-picking of windows.

We are happy to receive corrections. If you find a bug in the methodology
or code, the data files on this page will be updated and the change noted here.
