ICT Smart Money Concepts Order Block Indicator showing BOS, CHoCH, Order Block Demand/Supply zones, and Fair Value Gaps (FVG).
The ICT Smart Money Concepts & Order Block MT4 Indicator is a free custom technical indicator written in MQL4 for MetaTrader 4. Designed for traders who analyze market structure using ICT and Smart Money Concepts (SMC), this indicator automatically identifies Break of Structure (BOS), Change of Character (CHoCH), Fair Value Gaps (FVG), and potential bullish and bearish Order Block zones directly on your MT4 price chart with configurable alert notifications.
ICT Smart Money Concepts & Order Block MT4 Indicator Overview
What Is an Order Block in Smart Money Concepts?
In Smart Money Concepts (SMC) and ICT-style trading, an Order Block is commonly interpreted as a price zone associated with strong buying or selling activity prior to a significant market move. SMC traders often use these potential supply or demand zones to identify areas that may indicate significant buying or selling interest when price returns to them.
Rather than offering guaranteed evidence of commercial or central bank transactions, Order Blocks provide a structured technical framework that allows traders to mark key price levels where market momentum previously shifted rapidly.
Understanding BOS, CHoCH, and Fair Value Gaps (FVG)
Break of Structure (BOS)
A Break of Structure generally refers to price breaking an established swing point in the direction of the current market structure and is commonly used as a continuation confirmation.
Change of Character (CHoCH)
A Change of Character refers to a structural break against the previous directional structure and is commonly interpreted as an early indication that market direction may be changing.
Fair Value Gap (FVG)
A Fair Value Gap is commonly identified using a three-candle price imbalance where the range between the first and third candle is not fully overlapped by the middle candle. Traders often monitor FVGs as potential areas of interest, though imbalances are not guaranteed to be filled.
How the ICT Order Block MT4 Indicator Works
The ICT Order Block MT4 Indicator processes historical and live price data on MetaTrader 4 to automate structural charting analysis through the following algorithmic steps:
- Detect swing highs and swing lows based on configurable depth settings.
- Analyze market structure continuously across historical candles.
- Identify Break of Structure (BOS) and Change of Character (CHoCH) events.
- Detect potential Fair Value Gaps across three-candle imbalance patterns.
- Identify potential bullish and bearish Order Block zones.
- Draw relevant zones and structure information directly on the MT4 chart window.
- Trigger pop-up and audio alerts when configured market structure events occur.
How to Install the Order Block Indicator on MT4
Follow these step-by-step instructions to install the MQL4 Order Block indicator in your MetaTrader 4 terminal:
- Download the indicator file:
SmartMoney_OrderBlock_MT4.mq4. - Open your MetaTrader 4 trading terminal.
- Click File → Open Data Folder in the top menu bar.
- Navigate into the MQL4 → Indicators folder.
- Copy and paste the
.mq4file into the Indicators directory. - Restart MT4 or right-click inside the Navigator panel and click Refresh.
- Expand the Navigator → Indicators tree.
- Drag SmartMoney_OrderBlock_MT4 onto your active price chart.
- Configure custom indicator inputs (depth, colors, alert toggles) in the settings window.
- Check Allow DLL imports (if required by your system) and enable alerts if desired.
Supported MT4 Timeframes
The indicator can be used across all standard MetaTrader 4 timeframe charts from M1 up to Monthly (MN), adapting to different trading styles:
| Timeframe | Typical Use |
|---|---|
| M1 | Scalping & ultra-short-term execution |
| M5 | Scalping & lower-timeframe entry confirmation |
| M15 | Intraday structure analysis & trade timing |
| H1 | Day trading market bias & key level mapping |
| H4 | Swing analysis & major structural zone identification |
| D1 | Higher-timeframe trend directional bias |
Order Block vs BOS vs CHoCH vs FVG
| Concept | Purpose |
|---|---|
| Order Block | Potential supply or demand zone identified using SMC-style analysis |
| BOS | Structural continuation confirmation |
| CHoCH | Potential structural direction change |
| FVG | Price imbalance identified using a three-candle structure |
Combining these concepts allows traders to construct a structured analytical framework. For example, a trader might identify a higher-timeframe Order Block overlapping with an FVG, then drop down to a lower timeframe to wait for a CHoCH signal. While no individual technical concept or signal guarantees a profitable trade, combining structural elements provides a disciplined methodology for evaluating market behavior.
Key Features & Capabilities
Input Parameters & Settings Guide
Configure the indicator inputs inside MetaTrader MT4 via the Inputs tab upon attaching to your chart:
| Parameter | Default Value | Description | Recommended |
|---|---|---|---|
| InpStructureDepth | 5 | Fractal swing high/low depth sensitivity | 5 for Day Trading, 8-10 for Swing Trading |
| InpShowBOS | true | Plot Break of Structure continuation lines | True |
| InpShowCHoCH | true | Plot Change of Character reversal labels | True |
| InpShowFVG | true | Draw Fair Value Gap imbalance boxes | True |
| InpBullishOBColor | clrDarkGreen | Color for demand order block rectangles | Dark Green / Emerald |
| InpBearishOBColor | clrMaroon | Color for supply order block rectangles | Maroon / Crimson |
| InpEnableAlerts | true | Enable terminal popups & audio alerts on BOS/CHoCH | True |
Trading Strategy & Entry Rules
Step 1: Determine Higher Timeframe Market Bias
Evaluate the Daily (D1) or 4-Hour (H4) chart to observe overall structural direction, tracking whether price is forming consecutive bullish or bearish BOS breaks.
Step 2: Locate Unmitigated Order Blocks & Fair Value Gaps
Observe highlighted Order Block rectangles that contain unmitigated Fair Value Gaps (FVG) where price has not yet retraced.
Step 3: Wait for Price Retracement into the Zone
Monitor price as it approaches the Order Block demand or supply zone, avoiding chasing extended price moves.
Step 4: Confirm Lower Timeframe Shift (CHoCH)
Drop to lower timeframes (such as M15 or M5) as price enters the zone, providing a structural confirmation that traders may use to evaluate a potential entry.
Step 5: Define Risk Management & Target Levels
Place orders with stop loss levels set beyond structural invalidation points. Some traders use the next major liquidity or swing area as a potential target and may seek a favorable risk-to-reward ratio such as 1:3, depending on their strategy.
MQL4 Source Code
//+------------------------------------------------------------------+
//| SmartMoney_OrderBlock_MT4.mq4 |
//| Copyright 2026, TraderSentiments Quant Team |
//| https://tradersentiments.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2026, TraderSentiments"
#property link "https://tradersentiments.com/indicators/mt4/smart-money/orderblock-indicator"
#property version "2.10"
#property strict
#property indicator_chart_window
#property indicator_buffers 4
#property indicator_color1 clrLimeGreen
#property indicator_color2 clrCrimson
#property indicator_color3 clrDodgerBlue
#property indicator_color4 clrOrange
//--- Inputs
input int InpStructureDepth = 5; // Swing High/Low Depth
input bool InpShowBOS = true; // Display Break of Structure (BOS)
input bool InpShowCHoCH = true; // Display Change of Character (CHoCH)
input bool InpShowFVG = true; // Display Fair Value Gaps (FVG)
input color InpBullishOBColor = clrDarkGreen; // Bullish Order Block Box Color
input color InpBearishOBColor = clrMaroon; // Bearish Order Block Box Color
input bool InpEnableAlerts = true; // Popup Alerts on BOS/CHoCH
//--- Buffers
double BullishBOSBuffer[];
double BearishBOSBuffer[];
double BullishCHoCHBuffer[];
double BearishCHoCHBuffer[];
int OnInit() {
SetIndexBuffer(0, BullishBOSBuffer);
SetIndexStyle(0, DRAW_ARROW);
SetIndexArrow(0, 233);
SetIndexBuffer(1, BearishBOSBuffer);
SetIndexStyle(1, DRAW_ARROW);
SetIndexArrow(1, 234);
IndicatorShortName("ICT Smart Money Structure & Order Blocks (MT4)");
return(INIT_SUCCEEDED);
}How to Install & Compile in MetaTrader MT4
Follow this complete step-by-step technical guide to install, compile, and configure the custom MQL4 indicator on your desktop trading terminal:
Download Source File
Download the raw .mq4 source file to your computer using the direct download button below.
Open MT4 Data Folder
Open your MetaTrader terminal, navigate to the top menu bar, click File → Open Data Folder, and open the MQL4 → Indicators subfolder.
Copy & Compile in MetaEditor
Paste the downloaded file into the Indicators directory. Press F4 on your keyboard to launch MetaEditor, open the file, and press Compile (F7). Ensure the compiler reports 0 errors and 0 warnings.
Attach to Chart & Configure
Return to your terminal, refresh the Navigator (Ctrl+N) panel, drag the indicator onto your active chart, check Allow DLL imports (if applicable), and customize input parameters.
Integrating with Expert Advisors (EA) via iCustom()
Algorithmic traders and quant developers can seamlessly integrate this indicator into custom automated Expert Advisors (EAs). Because the indicator calculates values into standardized plot buffers on closed bars, you can query buffer values using native MQL4 functions without recompilation:
// MT4 MQL4 iCustom Calling Syntax Example
double signalBuy = iCustom(Symbol(), Period(), "SmartMoney_OrderBlock_MT4", 0, 1);
double signalSell = iCustom(Symbol(), Period(), "SmartMoney_OrderBlock_MT4", 1, 1);
if (signalBuy != 0.0 && signalBuy != EMPTY_VALUE) {
// Bullish signal confirmed on closed bar [1] -> Execute Buy Order
}
if (signalSell != 0.0 && signalSell != EMPTY_VALUE) {
// Bearish signal confirmed on closed bar [1] -> Execute Sell Order
}How to Set Up Mobile Push Notifications on iOS & Android
To receive real-time push alerts on your smartphone whenever an institutional signal triggers:
- Install the official MetaTrader MT4 app on your iPhone or Android smartphone.
- Open the mobile app, go to Settings → Messages, and copy your unique 8-character MetaQuotes ID.
- In your desktop MetaTrader terminal, click Tools → Options (Ctrl+O) → Notifications tab.
- Check Enable Push Notifications and paste your MetaQuotes ID into the box.
- Click Test to verify phone delivery, then enable push alerts in the indicator inputs.
Institutional Risk Management & Capital Preservation Protocol
Professional proprietary trading desks operate under strict risk control parameters to ensure longevity:
- Maximum 1% - 2% Risk Rule: Never risk more than 1% to 2% of total account equity on any individual trade setup.
- Minimum 1:2.5 Risk-to-Reward Ratio (RRR): Only execute setups where the potential profit target is at least 2.5 times greater than the stop-loss invalidation distance.
- Multi-Timeframe Confluence Required: Never take an intraday trade against the primary Daily or 4-Hour trend direction.
- High-Impact Economic News Awareness: Avoid entering new positions 15 minutes before and after major macroeconomic data releases (such as US Non-Farm Payrolls, CPI Inflation, and central bank FOMC/ECB interest rate announcements).
Strategy Backtesting & Historical Modeling Protocol
Before deploying any indicator or automated strategy in a live trading environment, professional quants conduct rigorous multi-year backtesting across varying market conditions:
- 99.9% Tick Data Modeling: Use high-precision tick history from reputable data providers (such as Dukascopy or TrueFX) to eliminate spread anomalies and slippage distortion.
- Spread & Commission Inclusion: Always test with realistic variable spreads and broker commission structures to simulate true real-world execution friction.
- Out-of-Sample Walk-Forward Optimization: Avoid curve-fitting by validating parameters on 70% in-sample data and testing robustness on 30% out-of-sample data.
- Monte Carlo Drawdown Analysis: Run randomized trade sequence simulations to calculate the maximum potential drawdown under adverse market volatility regimes.
Virtual Private Server (VPS) & Execution Latency Optimization
For active day traders, scalpers, and automated Expert Advisors, execution speed is paramount:
- Low-Latency Proximity Hosting: Deploy your MetaTrader MT4 terminal on a dedicated Windows VPS located in the same financial data center (e.g. Equinix LD4 in London or NY4 in New York) as your broker server to achieve sub-millisecond execution times.
- Terminal Memory Optimization: Go to Tools → Options → Charts and decrease Max bars in chart to 5,000 to conserve CPU and RAM resources.
- Audio & News Feed Disabling: Turn off unneeded terminal audio event chimes and background news feeds to ensure 100% of CPU cycles are dedicated to indicator calculations.
Common MetaTrader Error Codes & Resolution Matrix
| Error Code | Description | Exact Resolution Action |
|---|---|---|
| ERR_INVALID_STOPS (130) | Stop Loss or Take Profit is too close to current price. | Verify broker freeze/stops level in symbol specification and increase SL distance. |
| ERR_OFF_QUOTES (136) | Broker server has no available liquidity quotes. | Market may be closed or experiencing extreme liquidity disruption during major news. |
| ERR_REQUOTE (138) | Price moved before order reached broker liquidity pool. | Increase slippage tolerance deviation parameter in your order execution settings. |
| ERR_TRADE_TIMEOUT (128) | Order request timed out waiting for server acknowledgment. | Check internet connection latency or migrate terminal to a dedicated trading VPS. |
Institutional Quantitative Trading Lexicon
Broker Execution Models & Raw Spread Compatibility
To achieve optimal performance when using custom technical indicators:
- ECN / Raw Spread Accounts: Use True ECN accounts with 0.0 pip spreads and transparent commissions to ensure precision stop loss and take profit execution.
- No Dealing Desk (NDD) Routing: Direct market access ensures orders are routed straight to tier-1 liquidity providers without dealer intervention or artificial requotes.
- Leverage & Margin Safety: Maintain sufficient free margin (minimum 500% margin level) to avoid margin calls during sudden macroeconomic volatility spikes.
SmartMoney_OrderBlock_MT4.mq4
Version: v2.10File Size: 18.6 KBTotal Downloads: 15,000+License: Free Open SourcePlatform: MetaTrader MT4
Frequently Asked Questions

Quantitative algorithmic trading research desk specializing in MetaTrader MQL4/MQL5 automated systems, institutional order book mechanics, and risk management tools.
