

Kotak
Stockshaala
Chapter 4 | 3 min read
Understanding Strategy Tester (Backtesting Basics)
Before risking real money, every trader wonders:
“Will this strategy actually work?”
That’s where backtesting comes in.
TradingView has a built-in tool called the Strategy Tester. It allows you to test your trading ideas on past data to see how they would have performed before you use them in the live market.
What Is Backtesting?
Backtesting means running your trading strategy on historical data to check:
- How many trades it would’ve made.
- What the profit/loss would’ve been
- How often it won or lost.
Think of it like a flight simulator. You practice and refine before flying a real plane.
Where to Find Strategy Tester on TradingView
- Open any stock chart.
- Click on the “Strategy Tester” tab.
- You’ll see three main sections:
- Performance Summary
- List of Trades
- Settings
But before anything shows up, you need to apply a strategy, not just an indicator.
What’s the Difference Between a Strategy and an Indicator?
Indicator | Shows data like RSI, MACD | ❌ No |
Strategy | Includes buy/sell logic | ✅ Yes |
Strategies are coded in Pine Scripts™, TradingView’s scripting language. But don’t worry—you can use built-in strategies without writing any code.
How to Backtest Using a Built-In Strategy
Let’s say you want to test a basic Moving Average Crossover strategy:
- Buy when 9 EMA crosses above 21 EMA.
- Sell when 9 EMA crosses below 21 EMA.
Steps:
- Click on Indicators
- Search for “Moving Average Crossover Strategy”
- Add it to your chart.
- Click the “Strategy Tester” tab.
You’ll now see how this logic would have performed on the selected stock and timeframe.
What Metrics Should You Check?
Here are a few key things to look at:
Net Profit | Total gain or loss from all trades |
Win Rate (%) | % of trades that were profitable |
Max Drawdown | Largest loss during the test period |
Number of Trades | Total trades taken by the strategy |
Profit Factor | Ratio of total profit to total loss |
If your strategy has a low win rate and high drawdown, it might need improvement before real-world use.
Limitations of Backtesting
- Past performance ≠ future performance
- It doesn’t factor in slippage, real market volatility, or emotional decision-making.
- Works best when combined with forward testing (paper trading)
To Sum Up
The Strategy Tester is a powerful tool to test before you trade. Use it to check if your ideas hold up over time. Start with built-in strategies, and as you learn more, explore custom ones too.
Disclaimer: This article is for informational purposes only and does not constitute financial advice. It is not produced by the desk of the Kotak Neo Research Team, nor is it a report published by the Kotak Neo Research Team. The information presented is compiled from several secondary sources available on the internet and may change over time. Investors should conduct their own research and consult with financial professionals before making any investment decisions. Read the full disclaimer here.
Investments in securities market are subject to market risks, read all the related documents carefully before investing. Brokerage will not exceed SEBI prescribed limit. The securities are quoted as an example and not as a recommendation. SEBI Registration No-INZ000200137 Member Id NSE-08081; BSE-673; MSE-1024, MCX-56285, NCDEX-1262.
Recommended Courses for you
Beyond Stockshaala
Discover our extensive knowledge center
Learn, Invest, and Grow with Kotak Videos
Explore our comprehensive video library that blends expert market insights with Kotak's innovative financial solutions to support your goals.














