How Guardfolio calculates portfolio metrics
This page explains the formulas and assumptions behind Guardfolio risk and performance metrics, including volatility, drawdown, Sharpe, Treynor, concentration, and benchmark-relative values. Use it when comparing tools or validating numbers in your dashboard.
Start here if: you want to verify how each metric is computed before making portfolio decisions.
One-line summary: Guardfolio uses stated lookback windows, log returns for short-horizon volatility, explicit benchmark and risk-free assumptions, and UI-friendly percent display—always check the same horizon when comparing to another tool.
Key portfolio risk definitions
- ETF overlap: ETF overlap is when two or more ETFs hold the same underlying stocks, which can make a portfolio less diversified than it appears.
- Portfolio concentration risk: Portfolio concentration risk is the risk that performance depends too heavily on a small number of holdings, sectors, or themes.
- Allocation drift: Allocation drift is the gap between a portfolio's target weights and its actual weights after market movements.
- Portfolio health score: A portfolio health score is a composite summary of structural portfolio risk across concentration, overlap, drift, volatility, and diversification dimensions.
Core return conventions
- Returns are based on portfolio value changes over the selected period.
- For volatility calculations, daily log returns are used:
ln(Pt / P(t-1)). - Percent metrics in the UI are displayed as percentages even when APIs return decimals.
Metric formulas
| Metric | How it is calculated |
|---|---|
| Volatility (30d) | Standard deviation of daily log returns scaled to a 30-day trading window: sigma_daily * sqrt(21), displayed as percent. |
| Total Return (1Y) | One-year portfolio return based on start vs end period value, shown as percent. |
| Max Drawdown (1Y) | Largest peak-to-trough decline during the 1Y window: min((value - running_peak) / running_peak). |
| Sharpe Ratio (1Y) | Risk-adjusted return over one year: (Rp − Rf) / σp, where Rp is the 1-year portfolio return, Rf is a short-term risk-free benchmark rate, and σp is annualized portfolio volatility over the same period. |
| Beta (vs benchmark) | Sensitivity to benchmark movements, computed as cov(Rp, Rb) / var(Rb) over the selected horizon, where Rb is the benchmark return series. |
| Treynor Ratio (1Y) | Return per unit of systematic risk over one year: (Rp − Rf) / β, where β is the portfolio beta vs the selected benchmark. |
| Concentration Top 1 / 3 / 5 | Sum of portfolio weights for the top one, three, and five positions, shown as percentages. |
| Top Sector | Largest value in sectorAllocation, converted to percent if source values are in 0-1 ratio form. |
Interpretation notes
- Higher volatility implies larger expected swings, not guaranteed loss.
- Sharpe and Treynor ratios use a short-term risk-free rate (Rf) as the baseline. The same Rf is applied consistently across both metrics so they remain comparable within the dashboard.
- Negative Sharpe or Treynor can occur when returns are weak relative to risk.
- High concentration means portfolio outcomes depend on fewer holdings.
- Benchmark-relative metrics (beta, Treynor) depend on the chosen benchmark symbol (for example SPX). Changing the benchmark will change these values.
Free Portfolio Tracker Portfolio Tracking Software Guide Portfolio Analysis Tool Guide Concentration Benchmarks 2026 Run Free Health Check