MT4 error 4112: Automated trading disabled by trade server (ERR_TRADE_EXPERT_DISABLED_BY_SERVER)

The broker's server doesn't allow automated trading on this account. Turning on AutoTrading won't help; ask the broker.

4112ERR_TRADE_EXPERT_DISABLED_BY_SERVER
NoSafe to retry?
NoCould it have executed?

What it means

You see this code in GetLastError() in MQL4, raised inside the terminal.

The server, not the terminal, has switched off automated trading for this account. Manual trades may still work.

AutoTrading can be on in the terminal and this error still appears, because the block is on the broker's side. That is the difference from error 4109.

Common causes

  • An account type without automated trading.
  • An account group set up for manual trading only.
  • A broker restriction on the account.

How to fix it

  • Check whether a manual order from the terminal works, to confirm the block is only on automated trading.
  • Ask the broker to enable automated trading, or use an account type that has it.

Example in MQL4:

int ticket = OrderSend(Symbol(), OP_BUY, 0.10, Ask, 3, 0, 0, "", 4711);
if(ticket < 0 && GetLastError() == ERR_TRADE_EXPERT_DISABLED_BY_SERVER)
   Alert("The broker has disabled automated trading on account ", AccountNumber());

Is it safe to retry?

Not until the broker changes it.

Could the order have executed?

No. The server has switched off automated trading, so the request was refused.

How Tickwire handles it

Tickwire treats it like MT5 10026, and the MT4 code stays in the message. See trade results.

All MetaTrader error codes

One API for MT4 and MT5

Clear trade outcomes, idempotent orders and an audit log. Read the error reference or the quickstart.