Netting vs hedging in MT5 comes down to how positions are recorded. A netting account allows only one combined position per symbol, so new deals add to, reduce, close or reverse it, whereas a hedging account allows several separate positions on the same symbol, including a buy and a sell held at the same time.
Netting suits strategies that manage a single net exposure, while hedging is usually more flexible for Expert Advisors that manage individual trades. According to the MetaTrader 5 help, the system depends on the account and is set by the broker, so you cannot switch it on an existing account yourself.
The choice matters most to anyone running Expert Advisors, because an EA written for one system can behave very differently, or fail outright, on the other.
| Feature | Netting | Hedging |
|---|---|---|
| Positions per symbol | One combined position | Multiple, including opposite directions |
| Deal in the same direction | Increases the existing position | Opens a new, separate position |
| Deal in the opposite direction | Reduces, closes or reverses the position | Opens a new opposite position; the original stays open |
| Closing | An opposite deal of equal volume | Close each position explicitly, or use Close By |
| Typical use | Exchange-style accounting, one view of net exposure | Retail forex, multiple EAs or strategies per symbol |
The same trades on both systems
| Action | Netting account | Hedging account |
|---|---|---|
| Buy 1.0 lot EURUSD | Long 1.0 | Long 1.0 |
| Sell 0.4 lot EURUSD | Position reduces to long 0.6 | Long 1.0 and short 0.4, held separately |
| Open positions | 1 | 2 |
| Net directional exposure | Long 0.6 | Long 0.6 |
| Gross open volume | 0.6 lot | 1.4 lots |
Net exposure ends up identical, yet the structure differs: the hedging account carries more gross volume, two sets of stops and targets, and costs on both positions.
How netting and hedging work in MetaTrader 5
The netting system
Under netting, MT5 keeps a single common position for each symbol. If you are long 1.0 lot of EURUSD and buy another 0.5 lot, the position becomes long 1.5 lots at an averaged price, and if you then sell 1.5 lots, the position closes. Selling more than you hold reverses it, so selling 2.0 lots against a 1.5-lot long leaves you short 0.5 lot, and selling less than you hold simply reduces the position.
This keeps the account picture simple, since you always see one net exposure per symbol, but it means separate strategies on the same symbol cannot keep separate positions. If two EAs trade EURUSD on one netting account, their orders merge into one position, and a sell from one EA can partly close the other’s buy.
The hedging system
Hedging works the way most MT4 users expect. Each deal creates its own position with its own ticket, stop loss and take profit, and an opposite deal opens a new position rather than reducing the existing one, so a long and a short on EURUSD can sit side by side. Positions are closed individually, and the help notes that a position cannot be reversed on a hedging account; instead, one position closes and another opens.
MetaQuotes added the hedging option in MT5 build 1325 in April 2016, describing it as a way to expand the possibilities of retail forex traders. The same release introduced Close By, an operation that closes a position against an opposite one on the same symbol, which the release notes say allows traders to save one spread; when the volumes differ, the remainder stays open.
What happens to an EA on the wrong system
EAs written for MT4 usually assume hedging-style behaviour, with each order tracked by its own ticket and magic number. Running such an EA on a netting account can produce unexpected results: orders from different strategies merge, partial closes affect positions the EA did not intend to touch, and grid or hedging logic may not work at all. Many MT5 EAs check the account’s margin mode at start-up and refuse to run on an unsupported system, so read the EA’s documentation before attaching it.
In MQL5, an EA reads this with AccountInfoInteger(ACCOUNT_MARGIN_MODE), which returns one of three values listed in the MQL5 account properties reference:
- ACCOUNT_MARGIN_MODE_RETAIL_NETTING for over-the-counter netting,
- ACCOUNT_MARGIN_MODE_EXCHANGE for exchange-style netting, and
- ACCOUNT_MARGIN_MODE_RETAIL_HEDGING for hedging accounts.
Which system should you use for Expert Advisors?
For most retail forex traders running EAs, a hedging account is the practical default, because it lets several EAs or strategies trade the same symbol without interfering, keeps each order’s stop loss and take profit independent, and matches the way MT4-era code expects positions to behave. It also makes performance tracking easier, since each EA’s trades remain separate and can be grouped by magic number in a journal.
Netting suits traders who want one clear net position per symbol, those trading exchange-style instruments where the broker uses netting, and strategies written specifically for that model. It can also act as a discipline, since you cannot accumulate offsetting positions that hide your real exposure.
Before opening an account, ask the broker which system the account type uses, check that your EAs support it, and test on a demo account of the same type. In the Strategy Tester, run the EA with the same account settings you plan to trade, because results on a hedging test account will not reflect behaviour on a netting live account.
Holding opposite positions on a hedging account does not remove risk either: spreads, swaps and commissions apply to both sides, and a locked pair still has to be unwound later. Treat hedging as an accounting choice rather than a protection.
Frequently asked questions
Can I change an MT5 account from netting to hedging?
Not on an existing account. The accounting system is set by the broker for the account, so you would need to open a new account of the type you want, if your broker offers it.
How do I check whether my MT5 account is netting or hedging?
Check the account details provided by your broker or in the terminal, or ask the broker directly. An EA or script can also read the margin mode with AccountInfoInteger(ACCOUNT_MARGIN_MODE) and print the result.
Is MT4 netting or hedging?
MT4 handles orders individually, so it behaves like a hedging account: each order is separate and opposite orders can be held at the same time, subject to the broker’s rules.
Is hedging allowed for US traders?
Forex dealers regulated in the US are subject to NFA Compliance Rule 2-43, which restricts holding offsetting positions in the same currency pair, so US retail forex accounts generally cannot hedge in this way. Check with your broker for the rules that apply to your account.
Does netting or hedging affect drawdown?
Account equity reflects the marked-to-market value of everything that is open, whichever system you use, but hedging lets an account carry offsetting positions that hide gross exposure, while netting shows only the net position. Track equity during open trades on either system to see the real risk.
Next step
Check which system your MT5 account uses, confirm that each EA you run supports it, and test on a demo account of the same type before going live. If you run several EAs on a hedging account, give each a unique magic number and track them separately in a journal such as Account Tracker, which breaks trades down by magic number. Trading involves real risk, and neither accounting system protects you from losses.


Comments
No comments yet. Be the first to comment!
Leave a Comment
Your email address will not be published. Required fields are marked with *