February 5, 2026
ICT Order Blocks Explained: How to Trade the OB
Within the ICT trading methodology, Order Blocks represent one of the clearest footprints of institutional activity. They are not indicators, patterns, or retail concepts — they are zones where large market participants executed positions.
MQL5 order blocks explained

Introduction: Why Order Blocks Matter in Automated Trading

Within the ICT trading methodology, Order Blocks represent one of the clearest footprints of institutional activity. They are not indicators, patterns, or retail concepts — they are zones where large market participants executed positions. The beauty of Order Blocks is that they can be areas where large portions of limit orders rest and where the price is likely to return to and reverse from. 

There are a lot of variations floating around about how to identify and draw Order Blocks. This can lead to confusion as it’s unclear which method to hold on to for the best results. You will probably also notice how different educators teach different versions of Order Blocks and apply those versions randomly in their trading.

This is why automating a simple, straightforward Order Blocks concept is the key to consistently applying this ICT component to your trading. 

Since we focus on building automated trading systems for MetaTrader 5, we will refer to these systems as Expert Advisors (EAs)

What is an Order Block (ICT definition)

An Order Block is the last opposing candle before an impulsive move that leads to a market structure shift or displacement. There is often some uncertainty about what exactly a displacement is, but we’ve established a clear rule to make this completely mechanical. From an ICT perspective, this last opposing candle represents institutional order flow entering the market.

In the case of a Bullish Order Block, it means that we are looking to identify the last Bearish candle before a bullish impulsive move happens. 

Order Blocks are significant because they often act as:

  • Areas of accumulation or distribution
  • High-probability reaction zones
  • Structural support or resistance
Bullish order block explained

Structurally, an Order Block is identified by:

  • Liquidity is being taken before the impulsive move
  • A clear impulsive move in 2 candles
  • Identify the last opposing candle before the impulsive move

These characteristics make Order Blocks objective zones of interest rather than subjective trade entries. However, on lower timeframes, when stacked with other confluences, Order Blocks can be used to place trade orders directly.

Find an example where we used Order Blocks in a complete automated trading strategy here

How do we define an impulsive move? 

To automate the Order Block, you need mechanical rules for all of the elements. To identify a Bullish Impulsive move, we implemented the following rules in our EA: 

  1. Candle ID 2 (see the screenshot above) needs to close as a bullish candle
  2. Candle ID 2 needs to close above the high of candle ID 3
  3. Candle ID 1 needs to close as a bullish candle 
  4. The highest point of candles ID 1 and 2 needs to be above the highest point of candles ID 3 and 4

The screenshot above shows the candle ID numbers to help you understand better what these rules actually look like. 

Why Order Blocks Work (Institutional Logic)

Institutions cannot enter large positions with a single click. They require liquidity, time, and efficiency. Order Blocks can reflect those areas where institutions have tried to fill a large number of orders. The logic is that not all of their orders have been fulfilled, and the market has started to catch up with their activities, moving the price away from these areas.

When prices revisit these areas, the market often reacts — not by coincidence, but because unfilled or defended orders remain. You can use an OB as a strong reversal area.

Automating Order Blocks Using Profectus AI

With Profectus, traders can transform the Order Blocks concept into a fully automated module without writing code.

Using Profectus, you can:

  • Detect Order Blocks mechanically
  • Monitor invalidation conditions
  • Use the Order Block as an area to take a trade from
  • Apply consistent execution rules

This no-code trading approach allows traders to experiment, refine, and deploy institutional concepts in minutes.

Profectus AI order block strategy

I named the blocks to make it easier for you to understand what we’re doing in each Profectus block. We can divide the creation of this no-code EA for OBs into 3 steps. 

  1. Run per candle block. Start with this block to make sure that every new candle that is formed on the chart, the EA runs through the whole process of finding an OB, again and again. 
  2. Defining the OB using Trade Rule blocks. The 6 blocks that follow house the criteria for the OB. We already established that the OB is a 3-candle pattern with:
    2.1. liquidity grab
    2.2. Candles 1 and 2 showing impulsive strength
    2.3 The new rule here is the Liquidity grab. The low of candle ID 3 needs to be lower than the low of candle ID 4 to indicate a grab of liquidity on previous lows. 
  3. Store the OB price levels. Once an OB is found, we store it in a variable so that we can use this variable later to identify if the price comes back to it.
  4. Define a break of the OB to invalidate and remove it. A candle closing below the low of the Bullish OB invalidates the OB and deletes the OB price levels from the system. 

And that’s it! It only takes a few minutes to drag-and-drop the blocks and build the Order Block module in Profectus. You can now add an execution module to start taking trades, or add more rules to refine the OB, or add more confluences to the strategy. 

Deploying the Strategy as an MQ5 Bot on MetaTrader 5

Once automated, the Order Block strategy can be deployed as:

  • An MQ5 trading bot
  • Running 24/5 on MetaTrader 5
  • Executing trades exactly as designed once you add buy/sell blocks and rules

Why MT5?

  • Built-in algorithmic execution
  • Broker compatibility
  • Robust order handling
  • Industry-standard platform for automated trading

This allows you to move from manual chart analysis to mechanical automated trading.

Can You Automate Other ICT Strategies?

Yes. In our blog library, you can find a selection of automated ICT concepts and strategies

If a strategy has:

  • Clear rules
  • Defined conditions
  • Objective execution logic

It can be automated.

Order Blocks are just one example of how institutional trading concepts translate perfectly into algorithmic systems.

Get Access to the Order Block Automation Template

Want to see how this Order Block strategy works when fully automated?

Access an enhanced automation template used to turn this ICT concept into a deployable MQ5 trading bot inside Profectus. This template has a trade execution module included, so you can start testing it right away!


Disclaimer: Templates are for educational purposes only!

👉 Get the Order Block Automation Template → ICT OB Profectus template 

Watch the YouTube video here: https://youtu.be/75u7ccVHZt8?si=6CNJcD-7QOxvcATG