Value at Risk (VaR) Calculator for Trading Strategies

Calculate Value at Risk (VaR) for your trading strategy from a TradingView backtest CSV. Free, client-side, no upload or signup. Get VaR 95%, VaR 99%, and CVaR.

Calculate Value at Risk From Your Trades

What Is Value at Risk?

Imagine you run 100 trades on your strategy. You sort them by P&L from worst to best. Value at Risk (VaR) is the cutoff point where the worst 5 trades end. If that cutoff is a 2.3% loss, your strategy has a VaR 95% of 2.3%. It means 95 out of 100 trades lose less than 2.3%. The remaining 5 in 100, all bets are off. VaR has nothing to say about how bad those days get.

That blind spot is VaR's biggest weakness, and it is not a minor edge case. A strategy could have a tidy VaR 95% of 1.5% and still carry a 20% tail loss once every two years. VaR does not see the tail. CVaR (Conditional VaR, also called Expected Shortfall) fills that gap by averaging the losses that fall beyond the VaR threshold. Pineify computes both so you never rely on VaR alone.

Formula

VaR 95% = Percentile(P&L, 5) VaR 99% = Percentile(P&L, 1) In words: sort all trade (or daily) P&L values from worst to best. Take the value at the 5th percentile for 95% confidence, or the 1st percentile for 99% confidence. That number (negative) is your VaR. CVaR 95% = Average of all P&L values below VaR 95% Pineify computes VaR from the actual distribution of trade-level returns in your CSV, not from assumed normality.

How to Read This Number

VaR is expressed as a percentage of account equity or as an absolute dollar loss per trade. A VaR 95% of 1.8% means 95% of your trades (or days) lose less than 1.8%. The other 5% lose more, possibly much more.

Lower absolute VaR is better: less risk per trade. But VaR alone can mislead. A strategy with VaR 95% of 0.5% but VaR 99% of 12% has a fat tail: losses escalate fast in the worst cases. Compare the gap between VaR 95% and VaR 99%: the wider the gap, the fatter the tail. A tight gap (say 1.2% vs 1.8%) means losses are consistent. A wide gap (0.5% vs 12%) means tail risk dominates.

When I first looked at my own trend-following strategy's VaR numbers I was relieved: VaR 95% was a modest 1.1%. Then I saw VaR 99% at 9.4%. That nearly 9x jump told me the strategy was fine most of the time but occasionally got absolutely demolished. Without CVaR I would have missed how bad the bad days really were.

What Counts as Good?

RangeValueWhat It Means
Tight (low tail risk)VaR 95% < 1%, VaR 99% < 2%Losses are small and consistent. The gap between VaR 95% and 99% is narrow, meaning the tail is well-behaved.
ModerateVaR 95% 1-3%, VaR 99% 3-6%Typical for most directional strategies. Some tail risk exists. CVaR will tell you how bad the average tail event is.
Wide (fat tail warning)VaR 95% > 3% or VaR 99% > 6%Significant tail risk. A wide gap between 95% and 99% levels means the worst trades are much worse than the typical bad trade. Position sizing is critical here.

How Pineify Calculates Value at Risk

Pineify computes VaR 95%, VaR 99%, and CVaR from your TradingView Strategy Tester CSV automatically. The data is already in your CSV: every trade's gross profit and loss. We reconstruct the full return distribution and calculate percentiles directly from your actual results, not from a normal approximation. I ran my own diversified mean-reversion portfolio through it and expected VaR 95% around 0.5% given the win rate. The actual number came back at 1.8%. My mental model was wrong because I was mentally averaging wins and losses instead of looking at the distribution's left tail. The worst 5% of trades were far worse than I had internalized. That gap between expectation and reality is exactly why running the calculation on your real CSV matters. You get the VaR table, the CVaR complement, and the full returns distribution histogram, all in one view. No Python scripts, no Excel formulas, no permissions.

Get Your Value at Risk in Seconds

Upload your TradingView backtest CSV and get Value at Risk (VaR) plus 15+ other professional metrics. No signup needed.

Analyze Your Backtest Now

Frequently Asked Questions

Everything you need to know about this metric