How to use the portfolio volatility calculator
The page has two tools. Two assets shows the mechanics of diversification on the simplest case. Many assets handles a real portfolio and breaks its risk down holding by holding.
Two assets
- Weight in asset 1. The rest of the portfolio sits in asset 2, so 60 means a 60/40 split.
- Volatility of each asset: the annualized standard deviation of returns, in percent. The stock volatility calculator estimates it from prices, and fund factsheets often quote it.
- Correlation of the two return series, between −1 and 1.
Many assets
- List each holding with its weight (share of your capital) and annual volatility. The four defaults (stocks, bonds, gold and REITs) are example assumptions for illustration, not forecasts.
- Choose how to enter correlations. Full matrix takes one row per asset in the same order as the list, with 1s on the diagonal. Spreadsheet cells paste directly. One average correlation applies a single value to every pair, which is useful for a quick estimate or a stress test.
- Read the results, the risk table and the chart comparing each asset’s share of capital with its share of risk.
The calculator checks that the matrix has the right size, is symmetric, has 1s on the diagonal and is internally consistent (positive semi-definite). An inconsistent matrix, where the pairwise values cannot all be true at once, would produce a negative variance, so it is rejected rather than silently fixed.
The formulas
For any number of assets the same idea is written with the covariance matrix Σ:
MCi = ∂σp ÷ ∂wi = (Σw)i ÷ σp
RCi = wi × MCi Σi RCi = σp
Share of riski = wi(Σw)i ÷ σp2(Σw)i is the covariance of asset i with the portfolio. MC is the marginal contribution, RC the risk contribution. The contributions add up to σp because volatility is homogeneous of degree one in the weights (Euler's theorem).
Two more figures summarize the result. The diversification ratio is the weighted average volatility divided by the portfolio volatility; it equals 1 only when every correlation is 1. The effective number of risk sources is 1 ÷ Σ(share of risk)²: it equals the number of assets when every asset carries the same risk and falls toward 1 as one asset dominates.
The long-only minimum-volatility weight for two assets is:
A worked example
Two assets. A portfolio holds 60% in stocks with 16% volatility and the rest in bonds with 6%, and the two have a correlation of 0.2. The weighted average of the two volatilities is 12.00%, but the portfolio volatility is 10.35%: diversification removes 1.65% points. Stocks are 60% of the money and 90.3% of the risk.
Many assets. The default portfolio adds gold and REITs: 50% stocks, 30% bonds, 10% gold and 10% REITs, with the example correlation matrix. Portfolio volatility is 10.20% against a weighted average of 13.30%, a diversification ratio of 1.30.
The risk breakdown is lopsided. Stocks carry 74.3% of the risk and REITs, which correlate 0.7 with stocks, another 15.8%. Bonds carry 6.1% and gold just 3.8%. With an effective number of risk sources of 1.72, this four-asset portfolio behaves like fewer than two independent bets.
How correlation changes the answer
The chart on the two-asset tool draws portfolio volatility for every split at four correlations. At a correlation of 1 the line is straight: the portfolio is just a weighted average and nothing is diversified away. Every lower correlation bends the curve downward.
| Correlation of the 60/40 mix | Portfolio volatility | Stocks’ share of risk |
|---|---|---|
| 1 (no diversification) | 12.00% | 80.0% |
| 0.5 | 11.00% | 85.7% |
| 0.2 (the example) | 10.35% | 90.3% |
| 0 | 9.90% | 94.1% |
| −0.3 | 9.17% | 101.4% |
Lower correlation reduces volatility, and it concentrates the remaining risk further in stocks. Part of the bonds’ contribution comes from moving with stocks (the w1w2ρσ1σ2 term), so as the correlation falls their share shrinks. Below a correlation of −w2σ2 ÷ (w1σ1), which is −0.25 here, the bonds’ contribution turns negative: they act as a hedge, and stocks carry more than all of the risk. Stocks dominate at every correlation in the table because their volatility is so much higher; only the weights or the volatilities can change that.
Reading the risk contribution table
Marginal contribution is the rate at which portfolio volatility changes as you add a little of an asset. It also equals the asset’s volatility times its correlation with the whole portfolio, σi × ρi,p. Two practical consequences follow:
- Moving money between assets. Shifting a small slice of weight from asset j to asset i changes portfolio volatility by about (MCi − MCj) × the amount moved. The quickest way to cut risk is to sell what has the highest marginal contribution and buy what has the lowest, which is not always the least volatile asset.
- Hedges show up as negative contributions. An asset that is negatively correlated with the rest of the portfolio, or a short position, has a negative risk contribution: holding it lowers total volatility. Shares of risk still add to 100%, so other holdings then show more than 100% between them.
Risk ÷ weight compares an asset’s share of risk with its share of capital. Above 1 means the holding punches above its size. In the example stocks score above 1 and bonds far below, which is the imbalance that a risk parity portfolio sets out to remove.
Correlations in a stress
Diversification is measured with average correlations, but correlations between risky assets tend to rise in sell-offs. Rerunning the many-asset example with higher values (stocks and REITs at 0.9, stocks and bonds at 0.5) gives a volatility of 11.31% instead of 10.20%. Stocks’ share of risk falls to 68.8%, but only because bonds and REITs now move with them and take a larger share themselves: the total went up. Using a single average correlation of 0.3 for every pair gives 10.22%: close to the full matrix in total, yet it understates REITs’ share of the risk (10.3% instead of 15.8%) because it ignores how closely they track stocks. That is why the full matrix matters when you want to know where the risk sits, not just how much there is. You can estimate a matrix from your own return history with the correlation matrix calculator.
What this calculator does not include
- Expected returns. Volatility says nothing about reward. To weigh risk against return, use the Sharpe ratio calculator or the efficient frontier calculator.
- Estimation error. Volatilities and especially correlations estimated from a few years of data are noisy, and the result is only as good as those inputs.
- Tail risk. Standard deviation treats gains and losses alike and assumes the covariance describes how assets move together. It does not capture crashes, skew or the way correlations jump in a crisis. Value at risk and stress tests look at losses directly.
- Changing weights. The figures apply to the weights you enter. As prices move the weights drift, and so does the risk, until you rebalance.
- Currency, leverage costs and liquidity. Weights above 100% are treated as costless leverage, and cash is assumed to have zero volatility.