Portfolio VaR & Stress Test
Live risk analysis for any portfolio: Value at Risk (95% + 99%), Conditional VaR (Expected Shortfall), and stress-test scenarios across four historical crash magnitudes. Uses historical-simulation VaR from 500 days of actual daily returns. Zero data cost, delayed pricing.
What this tells you
Traditional portfolio metrics (return, volatility, Sharpe ratio) tell you what happened on average. Risk metrics tell you what happened in the tails — the days when things went badly. Two concepts drive institutional risk management:
Value at Risk (VaR)
Answers: "On the worst 5% of days over the last 500 days, how much did I lose?" A portfolio VaR95 of $2,500 means that 5% of days had losses of $2,500 or more; the 95% confidence interval for one-day loss is bounded at $2,500. Common variants: VaR99 (worst 1% of days, more conservative) and 10-day VaR (10-day horizon; scales by √10 from the 1-day value).
Conditional VaR (CVaR / Expected Shortfall)
Fixes VaR's blind spot. VaR tells you the boundary of the tail; CVaR tells you the average loss inside the tail. If VaR95 = $2,500 but CVaR95 = $4,000, then when you're actually in the worst 5% of days, your average loss is $4,000 — much worse than the VaR "boundary" suggests. CVaR is what regulators use for institutional risk.
How the numbers are computed
Historical simulation
For each of the last 500 trading days, compute what your portfolio's dollar P&L would have been given your current position sizes. Sort those 500 daily P&L values from worst to best. Then:
- VaR95 = 5th percentile (the 25th-worst day out of 500). Displayed as positive loss dollars.
- VaR99 = 1st percentile (the 5th-worst day). Higher confidence = larger loss.
- CVaR95 = mean of the 25 worst days.
- CVaR99 = mean of the 5 worst days.
10-day metrics scale by √10 (standard institutional convention under the assumption of daily i.i.d. returns).
Stress scenarios
Complementary to VaR: apply a hardcoded SPY move (-3%, -5%, -8%, -12%) to each position, weighted by its 60-day beta vs SPY, and compute the total portfolio dollar loss. The -12% scenario replicates the March 16, 2020 COVID-day sell-off (SPY's largest single-day loss in decades).
How to use these metrics
Position sizing
A common institutional rule: portfolio VaR95 ≤ 2% of capital. If your VaR95 exceeds this, reduce position size on the highest-contribution positions (typically high-beta names).
Stress-test comparison
The COVID-day (-12%) stress scenario is the modern reference point for "how bad can it get in one day." If that scenario shows a loss above your comfort zone, use the historical VaR/CVaR to size positions down until the stress case is manageable.
Combined with correlation
The correlation heatmap shows WHERE concentration risk lives. The VaR/CVaR here shows HOW MUCH that concentration costs on tail days. Together they inform position sizing at both the diversification and downside dimensions.
Frequently asked questions
Is historical VaR the best VaR method?
It's the most common and easiest to explain. Alternatives: parametric VaR (assumes normal returns, faster but underestimates tails) and Monte Carlo VaR (fully general but computationally expensive). Historical VaR captures actual fat tails and correlation regime shifts naturally.
Why 500 days of history?
Roughly 2 years of trading. Balance between having enough tail observations and reflecting current regime. Longer windows (1000+ days) give tighter tail estimates but risk mixing multiple market regimes.
Does VaR account for options positions?
Not directly. This scanner treats positions as underlying-only. If you have significant option overlays (long puts, short calls, etc.), your delta-adjusted VaR differs from the underlying-only VaR shown here. This is a known limitation; adding options overlay is a planned enhancement.
What are the limitations of VaR?
Three big ones: (1) it ignores the shape of the tail beyond the percentile (CVaR fixes this); (2) it assumes future returns behave like the historical sample (which they may not, especially in regime shifts); (3) it's not sub-additive — adding two portfolios can't always be summed VaR-wise. Real institutional risk management combines VaR with CVaR, stress tests, and scenario analysis.
How does this differ from Monte Carlo simulation?
Monte Carlo (like the wheel simulator) projects forward using bootstrapped or parametric random paths; VaR is a look-backward historical-simulation approach applied to today's positions. Both are legitimate tools; VaR is faster and better for daily portfolio management, MC better for multi-year outcome distributions.
Related tools
- Portfolio CC Optimizer — scan CCs across your CSV-uploaded portfolio.
- Portfolio Correlation Heatmap — complementary concentration risk view.
- Wheel Monte Carlo Simulator — forward-looking distribution analysis.
- Beta-weighted delta glossary — aggregate directional exposure metric.
- Value at Risk glossary — canonical definition.
- CVaR / Expected Shortfall glossary — the "average loss in the tail" complement.
Data source: Polygon.io daily aggregates. Educational only, not investment advice.