Stock Portfolio Backtesting Calculator

Backtest a multi-stock investment portfolio using real historical data — with dividends, DRIP, periodic contributions, and rebalancing strategies.

For educational purposes only. Past performance does not guarantee future results. Not financial advice.

1
Portfolio Composition
Required
Add tickers and set their weight allocations
Quick Start Presets(Optional)
or build your own below
Search or type a ticker below
TickerWeight (%)
1
2
2 of 15 tickers
Free
Free
See plans

You've reached the maximum number of tickers for your plan.

0%
Under-allocated

Add 100% to reach the target

2
Investment Details & Advanced Options
Required
Configure your initial investment and optional advanced settings
$

Min: $100, Max: $10,000,000

Historical data available from Jun 2011 on Free plan. Unlock more

Automatically reinvest dividends
Advanced OptionsOptional

Cashflow Timeline

Visual timeline editor for contributions, withdrawals & rebalancing

0/30 events
Months

Click and drag on any lane to create an event

Click the button above for a guide

Jun
Jul
Aug
Sep
Oct
Nov
Dec
Jan 2026
Feb
Mar
Apr
May
Jun
Contrib.
Withdraw
Rebalance

How the Portfolio Backtesting Calculator Works

The Stoculator portfolio calculator lets you simulate how a multi-stock portfolio would have performed using real historical market data. Enter your stock tickers, set allocation weights, choose a start date, and see detailed performance metrics including total return, compound annual growth rate (CAGR), time-weighted return (TWR), and maximum drawdown.

Features

  • Dividend reinvestment (DRIP) simulation — see the effect of reinvesting dividends on returns over time
  • Periodic contributions and withdrawals — model dollar-cost averaging with weekly, monthly, or quarterly contributions
  • Portfolio rebalancing strategies — simulate automatic rebalancing at various frequencies to maintain target allocations
  • Benchmark comparison — compare a portfolio's time-weighted return against the S&P 500 or other index funds
  • Drawdown metrics — view maximum drawdown percentage, drawdown periods, recovery times, and underwater charts
  • Asset and sector allocation charts — visualize how a portfolio is distributed across individual holdings and market sectors

Understanding the Results

After running a backtest, the calculator displays a results dashboard with portfolio summary metrics, a historical performance chart, allocation breakdowns, dividend timelines, and detailed per-holding analytics. All calculations use adjusted closing prices from historical market data.

Past performance is not indicative of future results. Simulated results are based on historical data and do not account for trading fees, taxes, or market impact. This tool is for educational purposes only and does not constitute financial advice.