Build an EA without writing code
Most traders have a strategy they can describe in a sentence and no way to turn it into a robot. The EA Builder closes that gap in the browser: you drag blocks for events, conditions and trade actions, connect yes and no outputs, and download a complete .mq4 or .mq5 source file. Compile it once in MetaEditor and it trades. This post explains what the builder can do, what it deliberately does not do, and how to go from a blank canvas to a tested EA.
How the builder thinks
An EA is a flowchart. Something happens (a new candle, a tick, a timer), the robot checks some conditions, and then it acts. The builder uses exactly those three block types:
- Events start a flow and have no input: On New Bar, On Tick, On Timer, On Trade, On Init, On Deinit.
- Conditions have a green yes and a red no output. Chain them for AND, fan one output into two blocks for OR.
- Actions do things: open or close orders, move stops, send alerts, set flags and counters. Trade actions also have an error output for when the broker rejects an order.
The generated code mirrors this one-to-one: every block becomes a small function, so the source stays readable if you later want to edit it by hand.
What is in the block library
- 36 indicators with all of their lines: moving averages, RSI, MACD (main and signal), Stochastic, Bollinger (upper, middle, lower), ATR, ADX with both DI lines, Ichimoku with all five spans, CCI, Williams %R, SAR, Alligator, Fractals, OBV, MFI and more. Each supports eleven conditions such as crosses above a value, price crosses below it, rising, falling, or line crosses second line.
- Custom indicator block for any iCustom file from your terminal, by buffer number.
- Price and candle blocks: candle direction, nine candle patterns, N-bar breakout, spread filter, price versus level.
- Time: trading hours with overnight windows, weekdays, once per bar, pause after the last trade.
- Trade checks: open trade count, pending count, floating profit, pips on the last trade, distance from the last trade for grids, balance and equity checks, daily loss and profit limits.
- Orders: market buy and sell, all four pending types, close all or partial, delete pending. Lot size fixed, percent risk from the stop, or per 1,000 of balance.
- Management: trailing stop, ATR trailing, break even, set SL and TP, close by age.
- Logic and code: flags, counters, random chance, and custom MQL condition, action and global code blocks for anything the library does not cover.
Every value becomes an input
By default every period, level, pip distance and lot size in your flow is written as an input in the generated file, grouped by block. That means you can change them in the EA properties without rebuilding, and you can run the Strategy Tester optimiser over them. Turn it off per block or globally if you want fixed numbers.
Strategy types to start from
Eight templates load a working flow you can edit: MA crossover with trailing stop, RSI mean reversion with trading hours, Bollinger breakout with ADX confirmation, MACD in the direction of the 200 MA with a daily loss limit, a stochastic M5 scalper, an averaging grid, and a London pending-order breakout. The built-in guide walks through four levels from a three-block EA to grids and custom code, and each level has a button that loads the matching template.
From download to a running robot
- Pick MT4 or MT5 at the top. Both platforms generate from the same flow.
- Download the file. It lands as
YourName.mq5or.mq4. - Copy it into MQL5/Experts (or MQL4/Experts), open it in MetaEditor and press F7. The generated code compiles clean on both platforms; if you have pasted custom code, the compiler line numbers point straight at it.
- Run the Strategy Tester, then a demo account. The demo guide applies to your own EA exactly as it does to a downloaded one.
What the builder does not do
- It does not compile for you. MetaEditor is free, ships with the terminal, and shows errors with line numbers. Keeping the compile on your side also means the tool works entirely in your browser with nothing uploaded.
- It does not backtest. The Strategy Tester is better at that than any web page.
- It does not promise the strategy works. It promises the code does what the flowchart says.
Small things people miss
- Bar shift 1 means the last closed candle. Shift 0 is the live candle and repaints until it closes.
- Under On Tick, put Once per bar or No open trades before an entry or you will open a trade on every tick.
- Stop loss, take profit and trailing are in pips. The spread filter is in points.
- Grey blocks in the palette are MT5-only indicators. Switch platform or swap them.
Every EA the builder produces carries the site name in its header and as the default trade comment, and draws a small metatraderea.shop label on the chart. Projects save in your browser and can be exported as a file to reopen later.
Frequently asked questions
Is the EA Builder free?
Yes. It runs entirely in your browser, nothing is uploaded, and the downloaded .mq4 / .mq5 file is yours to compile, edit and use.
Do I need to know MQL to use it?
No. You wire blocks and set numbers. The custom code blocks are optional for people who want to add their own MQL.
Does it produce MT4 or MT5 files?
Both. Choose the platform at the top and the same flow generates a .mq4 or a .mq5. A few indicators exist only in MetaTrader 5 and are greyed out when MT4 is selected.
Why does it not compile in the browser?
MetaEditor is free and already on your PC, and compiling there gives you exact error lines. It also means the builder never needs to upload your strategy anywhere.
Can I optimise the EA in the Strategy Tester?
Yes. Every block value is generated as an EA input, so the optimiser can sweep periods, levels and pip distances without any code changes.
Can I build a grid or martingale EA?
Grids yes, using the distance-from-last-trade, open-trade-count and floating-profit blocks. Lot multiplication after a loss is possible with the custom code block, but be aware of the drawdown such systems create.