Backtest any Indicator [Target Mode] StrategyUniversal Backtester Strategy with Sequential Logic
This strategy serves as a highly versatile, universal backtesting engine designed to test virtually any indicator-based trading system without requiring custom code for every new idea. It transforms standard indicator comparisons into a robust trading strategy with advanced features like sequential entry steps, dynamic target modes, and automated webhook alerts.
The core philosophy of this script is flexibility. Whether you are testing simple crossovers (e.g., MA Cross) or complex multi-stage setups (e.g., RSI overbought followed by a MACD flip), this tool allows you to configure logic via the settings panel and immediately see backtested results with professional-grade risk management.
Core Logic: Source vs. Target Mode
The fundamental building block of this strategy is the "Comparator" engine. Instead of hard-coding specific indicators, the script allows users to define logic slots (L1-L5 for Longs, S1-S5 for Shorts).
Each slot operates on a flexible comparison logic:
Source: The primary indicator you are testing (e.g., Close Price, RSI, Volume).
Operator: The condition to check (Equal/Cross, Greater Than, Less Than).
Target Mode:
Value Mode: Compares the Source against a fixed number (e.g., RSI > 70).
Source Mode: Compares the Source against another dynamic indicator (e.g., Close > SMA 200).
This "Target Mode" switch allows the strategy to adapt to almost any technical analysis concept, from oscillator levels to moving average trends.
Advanced Entry System: Sequential Steps (1-5)
Unlike standard backtesters that usually require all conditions to happen simultaneously (AND logic), this strategy implements a State Machine for sequential execution. Each of the 5 entry slots (L1-L5 / S1-S5) is assigned a "Step" number.
The logic flows as follows:
Stage 1: The strategy waits for all conditions assigned to "Step 1" to be true.
Latch & Wait: Once Step 1 is met, the strategy "remembers" this and advances to Stage 2. It waits for a subsequent bar to satisfy Step 2 conditions.
Trigger: The actual trade entry is only executed once the highest assigned step is completed.
Example Use Case:
Step 1: Price closes below the Lower Bollinger Band (Dip).
Step 2: RSI crosses back above 30 (Confirmation).
Execution: Buy Signal triggers on the Step 2 confirmation candle.
This creates a realistic "Setup -> Trigger" workflow common in professional trading, preventing premature entries.
Exit Logic & Risk Management
The strategy employs a dual-layer exit system to maximize profit retention and protect capital.
1. Signal-Based Exits (OR Logic) There are 5 configurable exit slots (LX1-LX5 / SX1-SX5). Unlike entries, these operate on "OR" logic. If any enabled exit condition is met (e.g., RSI becomes overbought OR Price crosses below EMA), the position is closed immediately.
2. Hard Stop & Take Profit
Fixed %: Users can set a hard percentage-based Stop Loss and Take Profit.
Trailing Stop: A toggleable "Trailing?" feature allows the Stop Loss to dynamically trail the price.
Longs: The SL moves up as the price makes new highs.
Shorts: The SL moves down as the price makes new lows.
Automated Alerts & Webhooks
This script is built with automation in mind. It includes a dedicated makeJson() function that constructs a JSON payload compatible with most trading bots (e.g., 3Commas, TradersPost, Tealstreet).
Alert Modes Supported: | Alert Type | Description | | :--- | :--- | | Order Fills Only | Triggers standard TradingView strategy alerts when the broker emulator fills an order. | | Alert() Function | Triggers specific JSON payloads defined in the code ("action": "buy", "ticker": "MNQ", etc.). |
The script automatically calculates the alert quantity based on your equity percentage settings, ensuring the payload matches your backtest sizing.
Dashboard & Visuals
To aid in rapid analysis, the strategy includes visual tools directly on the chart:
Performance Table: A dashboard (top-right) displays real-time stats including Net Profit, Win Rate, Profit Factor, and Max Drawdown.
Trade Markers: Custom labels (goLong, exLong) show exactly where trades opened and closed, including the trade number and profit percentage.
SL/TP Visualization: Dynamic step-lines (Orange for SL, Lime for TP) show exactly where your protection levels are sitting, helping you visually verify if your stops are too tight or too loose.
지표 및 전략
AlgoIndex NQ/MNQ FuturesAlgoIndex Futures v3.15 - NQ/MNQ (10-Minute RTH)
This strategy is specifically tailored for trading CME Nasdaq futures - NQ and MNQ, including continuous symbols such as NQ1!/MNQ1!. It is optimized for a 10-minute chart during U.S. Regular Trading Hours (RTH), utilizing session settings defined in the Inputs. This strategy is not intended for other futures contracts or markets.
Core Concept
The strategy employs an ATR-based trend-band model similar to Supertrend for identifying directional mechanism changes in NQ/MNQ. Trade signals are evaluated at the bar close, incorporating session and time-based safety techniques to mitigate lower-quality trading opportunities near session boundaries.
Recommended Use (Optimized Defaults)
The default input parameters are fine-tuned for NQ/MNQ on the 10-minute chart. Users are encouraged to utilize these defaults initially and to make incremental adjustments to one variable at a time to understand the impact on the strategy's performance, trading frequency, and risk profile.
Configurable Inputs
- Take Profit / Stop Loss Settings:
- Enable Stop Loss and define Stop Loss (Points)
- Enable Take Profit and define Take Profit (Points)
- Enable Trailing Stop and set both Trailing Stop (Points) and Trailing Offset (Points)
- Time Avoidance Filter:
- Enable Time Avoidance
- Avoid First X Minutes
- Avoid Last X Minutes
- Display Avoidance Zones (visual overlay)
- Session Filter and End-of-Day Management:
- Enable Session Filter
- Define Trading Session (default: 09:30-16:00)
- Select Session Timezone
- Option to Close Positions at Session End
- Specify EOD Close Minutes Before (default: 20)
- Safety Controls:
- Option to Close Before Holidays (when enabled, this feature allows the strategy to flatten positions prior to holiday or early close conditions)
- Automation Settings (Optional):
- Ticker Override (optional)
- Define Contracts (position size)
- Strategy Configuration:
- Trade Direction: Both / Long Only / Short Only
- Visual Configuration:
- Option to Show Buy/Sell Signals
- Highlight Trend Zones
- Display Info Table
- Customizable Bull/Bear Colors
Alerts and Automation (Optional)
This strategy can generate order-fill alert payloads for hooking into webhook-based automation solutions. Keep in mind to validate your alert type and your bridge/broker configuration during Replay and paper trading. Note that reversals may trigger two sequential actions (e.g., exit followed by new entry).
Backtest Notes (Optional)
For more precise historical fill data, consider enabling TradingView’s Bar Magnifier in Strategy Properties. Always apply consistent assumptions for commission and slippage when comparing backtest results.
Disclaimer
This script is intended for informational and educational purposes only and does not constitute investment advice. Trading futures carries significant risk and may result in losses that exceed the initial deposit. Backtested results are hypothetical and do not guarantee future performance.
Gann High Low Strategy## Trend & Structure Strategy — Overview
This strategy is designed to follow directional market moves by using a **dynamic price reference** to identify transitions between strength and weakness.
### Core concept
* It visually highlights when the market shifts from a **favorable phase** to an **unfavorable phase**, and vice versa.
* Signals are generated only when price behavior shows **minimum structural consistency**, helping to avoid random or low-quality conditions.
### Entries & trade management
* Entries aim to align with moments where price shows a **renewed directional intent**.
* Trade management is based on **technical price references**, allowing risk and objectives to adapt naturally to the current market context.
* Key directional and operational areas are clearly displayed on the chart to keep decision-making simple and visual.
### Best use cases
* Performs best in markets with **clear directional movement** and readable transitions.
* In very tight or choppy conditions, a more selective approach may be required.
*This content is for educational purposes only. Always test on different markets and timeframes before live use.*
Momentum Quality Index Strategyfiles.fm
Welcome to the Momentum Quality Index Strategy!
This is a fairly conservative strategy with a sharp criteria for entries and taking profits. This strategy has been tested amongst the top 50 stocks with volatility over 2%, and the verdict was that the profitability was often times over 85% profitability, often times reaching over 90% profitability. This strategy thrives in more volatile environments, often times beating the buying and holding strategy YTD performance by large margins.
This strategy is highly optimized for the 30 minute chart, giving insights into shorter term movements. It is based on cash trades of $1,000 per position, with a maximum of 4 trades being placed at once.
This strategy is optimized for common stock trading in more liquid markets, and not yet optimized for options trading (however I plan on developing highly profitable strategies for this purpose soon). The take profit is customizable.
I would refer to the image link I have posted at the top of this article for the strategy's effectiveness. The strategy report on this article isn't accurate, as this strategy is based on trading $1,000 per trade, therefore over longer term periods of time will not be as successful due to the fact that there is no compounding. However, over the course of smaller time frames (such as one year), it beats buying and holding of many assets.
This strategy is meant for day trading and short term swing trading, and is not meant to beat buying and holding of successful assets over the course of long periods of time.
ORB Strategy - EnhancedThis algo is for setting and forgetting ORB. Does require an understanding of how to tweak trading factors
Monarch Strategies Altcoin Optimized Cycle & Trend Strategy (1W)The Altcoin Optimized Cycle & Trend Strategy (1W) is a professional, long-term cycle and trend trading strategy designed specifically for altcoins such as Stellar (XLM). It is built for traders and investors who want to systematically capture explosive altcoin cycles while avoiding emotional decision-making and excessive trading.
The strategy operates on the weekly timeframe (1W) and focuses on identifying major accumulation zones, breakout phases, and distribution tops that typically define altcoin market behavior.
NIFTY T1 & T2 Strategy (65% SL, 15:15 Exit)Time based trading strategy without any indicator and reflecting operators move
Monarch Strategies BTC Optimized Cycle & Trend Strategy (1W)The "BTC Optimized Cycle & Trend Strategy (1W)" is a high-quality, long-term optimized trading strategy for BTC/USD, designed for traders and investors who want to systematically trade major market cycles — without overtrading, without emotions, and without unnecessary complexity.
The strategy is specifically built for the weekly timeframe (1W) and focuses on what Bitcoin has historically done best: strong, multi-year trend movements.
Long Bollinger Bands StrategyLong Bollinger Bands Strategy (XAUUSD) — Lower Band Reversal + 4-Step Scaling + Daily DD Guard
Long Bollinger Bands Strategy is a long-only Bollinger Bands reversal/mean-reversion strategy designed mainly for XAUUSD. It looks for a bearish push below the Lower Band followed by a bullish reclaim on candle close, then optionally scales in up to 4 entries (E1–E4) as price pulls back.
1) Risk Management & Position Sizing
The strategy includes a USD-based risk input: Risk per setup (USD).
It automatically calculates position size using the average SL distance across the 4-entry structure, then distributes size across entries with built-in weighting.
BackTest Lot checkbox:
OFF (default): uses normalized sizing (qty divided by 100)
ON: uses raw qty for backtesting workflows
2) SL/TP Management (Locked SL + Optional Range TP)
Stop Loss (SL): based on SL distance (pips from entry) from E1.
Take Profit (TP):
If TP (pips) > 0: fixed pip TP from E1
If TP (pips) = 0: TP is based on the signal candle range (high–low)
SL Lock: once the stop is tightened, it never loosens again (only moves in a protective direction) until the trade closes.
3) Daily Drawdown Protection
Tracks equity by day and stops opening new positions once Max daily drawdown (USD) is reached for that day.
4) Notes / Disclaimer
This strategy does not use volume, RSI, fundamentals, news filters, or session filters. Users should apply discretion and consider confirmations from other tools and market context. Results depend on symbol settings, spread, commission, and volatility regime. Always forward-test before using in live trading.
Designed for XAUUSD. The script uses an internal pip conversion (pipSize = 0.1) consistent with common gold quoting; verify your broker’s pip definition for best alignment.
5) Suggested Usage
Best used during volatile conditions or after a clear lower-band sweep and reclaim.
Consider pairing with trend filters or higher-timeframe bias.
6) Release Notes
Initial release: Long-only BB reclaim logic with 4-step scaling
Added: SL/TP lock logic and visual SL/TP lines
Added: Daily drawdown guard and backtest lot toggle OANDA:XAUUSD
Nifty-50 Futures Trading Ideas/ Strategyb]Nifty-50 Futures Trading Ideas is a trend-following strategy designed for study and backtesting .
The strategy identifies directional bias using a structured price-based approach and applies ADX + DI and RSI filters to validate trend strength.
It includes inbuilt risk-management logic such as Stop-Loss, Take-Profit, ATR-based exits, separate maximum loss per trade (₹) for long and short positions, and optional date/session filters.
This script is provided for educational and analytical purposes only and is not a trading signal or investment recommendation.
Quantum X StrategyQuantum X Strategy is a structured market-behavior based trading model developed for Midcap Nifty on the 15-minute timeframe.
It focuses on identifying directional strength, momentum alignment, and price participation using a multi-factor confirmation approach.
Rather than relying on a single indicator, the strategy evaluates multiple dimensions of price movement to determine whether the market environment is favorable for participation. This helps in avoiding random entries during low-quality or sideways conditions.
🔍 Conceptual Framework
The strategy dynamically observes:
Momentum expansion and contraction
Trend participation strength
Directional consistency over recent price action
Each market condition contributes to an internal decision process, allowing trades only when sufficient alignment is present. This approach helps filter out noise and improves trade selectivity.
📊 Trade Execution Philosophy
Trades are initiated only when market structure shows clear directional intent
Both bullish and bearish opportunities are evaluated independently
Positions are exited when momentum balance weakens or returns to a neutral state
No over-trading during indecisive phases
The system is designed to stay inactive during uncertain market conditions, which is a key part of its risk-aware behavior.
🕒 Backtesting Scope
For consistency and reliability, the strategy logic is activated only from January 2024 onward, ensuring analysis is focused on recent market behavior rather than outdated volatility patterns.
⚙️ Usage Guidelines
Instrument: MIDCAPNIFTY
Timeframe: 15 Minutes
Suitable for intraday and short-term positional observation
Works best when combined with disciplined risk management
⚠️ Disclaimer
This strategy is provided strictly for educational and research purposes.
Market conditions change, and past performance does not guarantee future results. Users should always forward-test and apply their own risk management before live use.
Time Syndicate: Prop Firm SpecialTime Syndicate – Prop-Firm Special (Exit-Focused Edition)
Overview
Time Syndicate – Master Strategy is a non-repainting, cycle-aware execution framework designed to trade structured market phases rather than random price movement.
This version has been specifically updated to focus on exit efficiency , trade management, and controlled trade churn.
The strategy is built to align trades with time-based market behavior and liquidity expansion, without relying on indicator stacking or repainting logic.
What This Version Is Optimized For
This update emphasizes:
• More structured exits
• Increased trade churning
• Improved realized profitability
• Mechanical trailing stop execution
The goal is not to increase entries, but to extract more value from correct ones .
Recommended Markets
• EUR/USD
• NASDAQ (NQ / US100 Cash CFD)
This strategy is primarily designed and tested for these instruments.
Recommended Cycles & Timeframes
90-Minute Cycle → Use 1-Minute chart
Session Cycle → Use 5-Minute chart
Do not mismatch cycle selection and chart timeframe.
Important Settings (Do Not Over-Optimize)
• Exit Mode: Trailing Stop (Default & Recommended)
• Max Trades Per Cycle: 1
• Target: 1 : 1.5
• Most other settings should remain unchanged
This is not a parameter-tuning strategy.
Trade Behavior
• Trade Status remains FLAT until a valid trade is triggered
• After entry, the dashboard displays:
– Entry Price
– Initial Stop Loss
– Trailing Trigger Level
– Live Trailing Stop (once activated)
In most cases, the entry candle’s low/high will act as the initial stop loss.
Exit Logic
Trailing Stop Mode
• Trailing activates only after price reaches the required expansion level
• Trailing is mechanical and non-emotional
• Live trailing stop updates are shown clearly on the chart
Fixed Target Mode
• Available for testing purposes
• Not recommended for live execution
Non-Repainting Logic
• All zones, cycles, and trade logic are non-repainting
• No historical shifting
• What appears live is final
Known Limitations (Current Version)
• Quantity calculation can be aggressive, especially on 1-minute charts
• Manual quantity is recommended for now
• Not every valid signal should be traded
These will be refined in future updates.
Recommended Trading Window
For US100 Cash CFD:
4:00 PM – 8:00 PM IST
Outside this window, liquidity behavior becomes inconsistent.
Advanced Usage Tip
Download strategy trade data and analyze:
• Time of day
• Cycle performance
• Trade outcomes
Use this data to determine the most effective trading hours for your instrument.
Purpose of This Strategy
This is not a signal-spamming indicator.
It is a professional execution framework built to:
• Enforce discipline
• Improve exit quality
• Reduce emotional decision-making
• Align trades with structured market phases
Final Note
This strategy does not predict the market.
It waits, reacts, and extracts.
Use it with patience, proper risk control, and respect for time-based structure.
Smart Money Bot [MTF Confluence Edition]Uses multi-time frame analysis and supply and demand strategy.
Best used when swing trading.
Wealth Pilot AlphaTrend + RSI StrategyWealth Pilot AlphaTrend + RSI Strategy
Works on Multi Time frames and across Different pairs
Phoenix H4-M15 v1Public Release: Phoenix Capital H4-M15 Trading Strategy v1
We are excited to release a public version of our custom trading indicator! This strategy is designed to help you identify market trends with precision.
Supported Assets:
• Crypto: BTC, ETH
• Indices: NQ (Nasdaq), ES (S&P 500)
• Commodities: XAU (Gold)
Join Phoenix Capital: t.me
Nifty-50 Futures trading ideas with RSI and ADX FilterNifty Futures @15M is a trend-following strategy derived from the Savitzky Flow Bands methodology by ChartPrime , adapted into a complete strategy with structured trade execution and risk controls.
The strategy identifies directional bias using a Savitzky-smoothed price structure and executes trades based on trend changes or continuation, depending on the selected entry mode.
Configurable Entry Modes are : 1. Change Only (trend reversal based) 2.Continuation Allowed (trend follow-through).
Optional ADX + DI and RSI filters help validate trend strength and avoid unfavorable market conditions.
Risk management features include configurable Stop-Loss and Take-Profit, ATR-based exits, trailing stop, and separate maximum loss per trade (₹) for long and short positions.
Date and session filters are provided for controlled backtesting.
This script is published for educational and analytical purposes only and is intended for research and backtesting, not as a trading signal or investment recommendation.
Credits:
Original indicator concept: Savitzky Flow Bands by ChartPrime
Strategy conversion & enhancements: @Alpha_Trinity
FxAST LiteWave Universal Profiles (intraday / swing)FxAST Lite Wave — Universal (Profiles)
This strategy is intended for educational and analytical use.
Derivative works must retain attribution and license terms.
_____________________________________________________________________________
Overview
FxAST Lite Wave is a rule-based trend participation strategy designed to adapt across multiple markets and timeframes using a simple profile switch.
Rather than attempting to predict reversals or tops and bottoms, the strategy focuses on identifying continuation opportunities once directional alignment and market participation are already present.
Its purpose is to provide a structured, repeatable framework for studying trend behavior and managing trades within established directional moves.
_______________________________________________________________________________
How It Works
FxAST Lite Wave evaluates market conditions using a layered confirmation process that includes:
• Directional bias
• Trend alignment
• Momentum participation
• Volatility suitability
• Market regime awareness
Trades are only considered when these conditions align, helping to reduce low-quality signals and overtrading during unfavorable environments.
Two built-in profiles are provided:
Intraday — designed for shorter-term participation
Swing — designed for higher-timeframe continuation
_______________________________________________________________________________
Core Concepts (Plain English)
Direction
Identifies which side of the market is currently in control.
This answers:
“Is pressure aligned for continuation?”
_______________________________________________________________________________
Momentum
Confirms that price is moving with intent rather than drifting or stalling.
This answers:
“Is participation present?”
_______________________________________________________________________________
Regime
Filters out unfavorable conditions such as congestion, compression, or low-energy chop.
This answers:
“Is this a tradable environment?”
_______________________________________________________________________________
Continuation Focus
Entries are designed to occur after alignmen t, not at arbitrary turning points.
The strategy favors:
• Pullbacks within trend
• Momentum resumption
• Sustained directional movement
_______________________________________________________________________________
Risk & Trade Management
FxAST Lite Wave includes structured trade management logic:
• Volatility-aware initial risk
• Optional partial profit taking
• Optional breakeven and trailing behavior
• Optional time-based exits
• Optional equity-based position sizing
A built-in on-chart Backtesting HUB displays live performance statistics for transparency and review.
_______________________________________________________________________________
Philosophy
FxAST Lite Wave is intentionally not a signal-spamming strategy .
It is designed to:
• Reduce decision fatigue
• Encourage rule-based consistency
• Support disciplined execution
If you need:
precise entries → use price action
precise exits → use structure
system context → use Lite Wave
_______________________________________________________________________________
Disclaimer
This strategy is provided for educational and analytical purposes only and does not constitute financial advice. Trading involves risk, and users are responsible for their own decisions. responsible for their own decisions.
Estrategia_XAU_1m_NYEstrategia para el par XAU/USD temporalidad 1 minuto, de 9:30 a 10:00 am New York. Solo media hora al dia.
Strategy for the XAU/USD pair, 1-minute timeframe, from 9:30 to 10:00 am New York. Only half an hour per day.
Smart Money Liquidity Structure AlgoSmart Money Liquidity Structure Algo is a rule-based trading strategy designed to analyze market structure, liquidity zones, and volatility conditions.
The script combines structure breakout logic, volatility filtering, order-block style price gaps, and Supertrend direction to generate systematic long and short signals.
This strategy is intended for educational and research purposes, helping traders study how liquidity, structure, and trend alignment can be combined into a single framework.
All signals are generated objectively using predefined conditions without repainting after bar close.
The strategy includes built-in risk management logic using ATR-based stop-loss and trailing exit mechanisms.
⚙️ Core Logic Overview
Market structure based on pivot-derived support and resistance
Volatility normalization filter to avoid low-activity periods
Price gap detection inspired by order-block concepts
Supertrend-based directional confirmation
Time-based holding logic before exits are allowed
✨ Features
Rule-based long and short entries
Liquidity & structure breakout detection
Volatility-filtered signal generation
Optional Supertrend trend filter
ATR-based stop-loss and trailing exits
Non-repainting logic after candle close
🧪 How to Use
Apply on liquid markets such as crypto, indices, or forex
Works best on intraday to higher timeframes
Adjust volatility filter and ATR multiplier based on the instrument
Always forward-test and paper-trade before live use
⚠️ Disclaimer
This script is not financial advice.
Trading involves risk, and past performance does not guarantee future results.
Use this strategy for analysis, testing, and educational purposes only.
Crypto LONG PYThis trading approach is a powerful combination of technical tools aimed at taking advantage of market fluctuations with precision and reliability. By integrating Bollinger Bands (BB), the Relative Strength Index (RSI), Exponential Moving Averages (EMA), and Fibonacci retracement levels (Fib), we create a strategy that captures key market moves and helps identify optimal entry and exit points, all within the context of the New York market conditions (NY).
Bollinger Bands provide insight into market volatility, offering signals about potential extreme price movements. The RSI is used to measure momentum and assess overbought or oversold conditions, indicating when the market might be nearing a reversal. Meanwhile, EMAs add a layer of smoothing, allowing us to observe short- and medium-term trends, helping filter out false signals and providing a clearer view of the overall market direction.
Additionally, Fibonacci retracements are integrated to identify key support and resistance levels, pinpointing potential areas of price retracement and continuation. When combined, these indicators offer a holistic approach to navigating the markets, enabling traders to make data-driven, informed decisions.
This approach is ideal for traders looking for a meticulous methodology for trading during the NY session, where liquidity and volatility tend to be at their highest. Leverage the synergy between these indicators to optimize your trading strategy and maximize your market performance.
USOIL BOS Retest Strategy 2.0 This is generating 4.73% return nothing wow but will form the base of my trading engine
Velocity SwingtraderThe intended objective of this indicator to gauge trend and momentum and find trades that are at the beginning of a trend change for longer periods of time (days, weeks, months).
Range Strategy (kasatura84)Winning Range Strategy (Set Heikin Ashi Candles)
Incredible winning strategy. You have to set Heikin Ashi Candles to activate strategy! It works both long and short trades.






















