MetaTrader 4 and MetaTrader 5 look alike, come from the same company and both run expert advisors and indicators. Underneath, they are different programs with different programming languages, order systems and strategy testers. This guide covers the differences that change how you trade and which tools you can use.
The short answer
MetaQuotes released MT4 in 2005 as a platform for forex. MT5 followed in 2010, built to handle exchange-traded markets such as stocks and futures as well as forex and CFDs. MT5 is the platform MetaQuotes now develops most actively, and many newer brokers offer only MT5. MT4 is still widely used, largely because of the huge library of MT4 indicators and EAs that traders have built up over the years.
For most traders the decision comes down to three practical questions: which platform your broker offers, whether the tools you rely on exist for it, and how much you use the strategy tester. One rule applies whichever you pick: a tool built for one platform doesn't run on the other. If you are new to automated trading, our guide to expert advisors explains what an EA does before you choose where to run one.
MT4 and MT5 side by side
| Feature | MT4 | MT5 |
|---|---|---|
| Programming language | MQL4 (.mq4 source, .ex4 compiled) | MQL5 (.mq5 source, .ex5 compiled) |
| Timeframes | 9 | 21 |
| Account modes | Hedging only | Netting or hedging, set by the broker |
| Pending order types | 4 | 6, adding Buy Stop Limit and Sell Stop Limit |
| Strategy tester | Single-threaded, one symbol per test | Multi-threaded, multi-symbol, real ticks, cloud agents |
| Depth of market | No | Yes, where the broker supplies it |
| Economic calendar | No | Built in, and readable by EAs |
| Application | 32-bit | 64-bit |
| Runs the other platform's files | No | No |
Orders, hedging and netting
This is the difference most likely to catch out an expert advisor, so it's worth understanding before you open an MT5 account.
Hedging accounts
Every trade is its own position with its own ticket, stop loss and take profit. You can hold several buys and several sells on the same symbol at the same time. MT4 works only this way, and MT5 hedging accounts behave the same.
Netting accounts
You hold at most one position per symbol. A new buy on a symbol where you are already long adds to that position. A sell reduces it, closes it or reverses it. This is how exchange trading works, and it was MT5's only mode until MetaQuotes added hedging accounts.
The broker sets the mode when the account is opened, and you can't switch it inside the terminal. Your account details from the broker say which one you have. If they don't, ask before you attach an EA.
Why the mode matters for EAs
An EA written for a hedging account may open a sell while it holds a buy, expecting two separate trades. On a netting account that sell closes or shrinks the buy instead, and the EA's own bookkeeping no longer matches the account. Grid EAs, hedging EAs and many recovery systems depend on holding opposite positions, so they need a hedging account. Check the EA's documentation for the account type it expects.
Pending orders and trade records
MT4 offers four pending orders: Buy Limit, Sell Limit, Buy Stop and Sell Stop. MT5 adds Buy Stop Limit and Sell Stop Limit. When price reaches the stop level, the platform places a limit order at a second price you set, which lets you wait for a breakout and then try to enter on a pullback.
Record keeping differs too. MT4 calls every trade an order. MT5 separates orders (your requests), deals (the executions) and positions (what you hold), and its History tab can show any of the three. Trade reports, journals and copiers built around one model need adjusting for the other.
Charts, timeframes and indicators
MT4 offers nine timeframes: M1, M5, M15, M30, H1, H4, D1, W1 and MN. MT5 offers 21, adding M2, M3, M4, M6, M10, M12, M20, H2, H3, H6, H8 and H12. MT5 stores one-minute bars and builds every other timeframe from them, which is how it can offer so many. If your strategy uses an unusual timeframe such as H2 or H8, MT5 shows it natively, while MT4 needs a script to build an offline chart.
Both platforms ship with the standard indicators most traders use, including moving averages, RSI, MACD, Bollinger Bands, Stochastic and ATR, and both accept custom indicators. MT5 includes more built-in indicators and drawing objects.
Where the broker provides it, MT5 can show real exchange volume and a depth of market window. Spot forex has no central exchange, so on most forex accounts you see tick volume on both platforms. Tick volume counts how many times the price changed, not how much was traded.
Day to day, the two look similar enough that switching takes little time. Market Watch and the Navigator sit in the same places, the trade and history tabs run along the bottom (in a panel called Terminal in MT4 and Toolbox in MT5), and both offer one-click trading from the chart.
The strategy tester
If you test EAs, the tester is the strongest practical reason to prefer MT5.
- Speed. MT4's tester runs on a single processor core. MT5 spreads tests and optimizations across every core on your computer, can use other computers on your network as test agents, and can rent capacity from the MQL5 Cloud Network.
- Tick data. MT4 builds ticks from one-minute bars, so its “Every tick” mode estimates how price moved inside each minute. MT5 adds “Every tick based on real ticks”, which replays the broker's recorded tick history.
- Spreads. MT4 tests with one fixed spread, either the current spread or a number you enter. MT5 can use the spread stored in history, which widens and narrows the way the live spread does.
- Multiple symbols. An MT4 test covers one symbol. An MT5 EA can read and trade several symbols in a single test, which matters for portfolio and correlation strategies.
- Forward testing. During optimization, MT5 can hold back the end of your date range and run the best settings on it. It's a quick first check for curve fitting.
A faster tester doesn't make a strategy better, and real tick testing is only as good as the broker's stored history. Our backtesting guide walks through modelling modes, data and the test report on both platforms.
Extras built into MT5
A few MT5 features have no direct MT4 equivalent:
- Economic calendar. The Calendar tab in the Toolbox lists scheduled releases, and MQL5 programs can read the same data. An MT5 EA can pause around high-impact news without outside files, while an MT4 EA needs a web feed or a separate tool for that.
- Depth of market. On instruments where the broker streams it, MT5 shows the order book and lets you place orders from it.
- Python integration. MetaQuotes publishes an official Python package that reads prices and history from a running MT5 terminal and can send orders. It's useful if you research strategies in Python.
- 64-bit design. MT5 can use more of your computer's memory, which helps with long tick histories, many charts and large optimizations.
Some things are the same on both. Each platform has a built-in virtual hosting service, push notifications to the MetaTrader mobile app, and similar chart tools and order windows.
Why EAs and indicators don't cross over
MT4 loads only .ex4 files and MT5 loads only .ex5 files. There is no converter, and renaming a file does nothing. Since a 2014 update, MQL4 shares much of its syntax with MQL5, but the parts an EA relies on most are different:
- Trading functions. An MQL4 EA opens and closes orders with a short list of parameters. An MQL5 EA fills in a trade request and then works with positions and deals, and it has to handle netting accounts.
- Indicator calls. In MQL4, a call such as
iMA()returns a value directly. In MQL5 it returns a handle, and the code copies values out withCopyBuffer(). - Price data. The built-in MQL4 arrays such as
Close[]and theBidandAskvariables don't exist in MQL5, which uses its own functions to request prices.
Moving an EA from MT4 to MT5 is therefore a port, not a recompile. A developer rewrites the trading and data code, and the new version has to be tested from scratch, because small differences in execution and data can change results. Indicators are usually simpler to port, but they still need rewriting.
The same separation applies to accounts. Brokers run separate MT4 and MT5 servers, so an MT4 login won't connect in MT5. Installation also differs by platform: MT4 tools go into MQL4/Experts or MQL4/Indicators, MT5 tools into MQL5/Experts or MQL5/Indicators, all found through File > Open Data Folder. Our installation guide covers the full steps.
Which platform should you use?
There's no single right answer, but these questions settle it for most traders:
- What does your broker offer? Some brokers and prop firms support only one platform, and some offer only certain account types on each. That can decide it before anything else.
- Do your tools exist for it? If an indicator or EA you depend on is available only for MT4, that keeps you on MT4 until an MT5 version exists. When you browse the catalog, check the platform on each product before you buy.
- How much do you backtest? If you optimize EAs or test on long periods, MT5's tester saves hours and gives more realistic tick data.
- Does your strategy hold opposite positions? Grid and hedging EAs usually need MT4 or an MT5 hedging account, not a netting account.
- Are you starting fresh? With no existing tools to carry over, MT5 is a sensible starting point because it is the platform MetaQuotes is actively developing.
Plenty of traders run both: MT4 for an older tool they know well and MT5 for newer ones. The two install side by side on the same computer or VPS without interfering with each other. If you have an MT4 strategy you'd like to run on MT5, our custom development service can build an MT5 version to your rules.