Your EA Won't Stop Knocking. MT5 Says Too Many Requests (10024).
Imagine an Expert Advisor that has discovered a revolutionary new trading strategy: ask the server the same question fifty times and hope it eventually gets a different answer.
The server is unimpressed.
If MT5 returns 10024 — Too frequent requests, the problem is not that your robot lacks enthusiasm. It may have rather too much of it.
MetaQuotes names this trade-server return code TRADE_RETCODE_TOO_MANY_REQUESTS . It means the server has rejected a request because requests are arriving too frequently. It does not identify the faulty line of code, disclose a universal rate limit, or prove that an order was never executed.
A trade request is not necessarily a new trade
Developers sometimes count only Buy and Sell submissions. But an EA can also send trade requests to modify stops, change pending orders, or close positions.
Consider a purely hypothetical trailing-stop routine. The market ticks. The routine calculates a stop at 2350.10 and submits a modification. Another tick arrives. The calculation still says 2350.10. The EA sends the identical modification anyway.
Repeat that pattern during an active market and you have a robot repeatedly ringing a doorbell while already standing inside the house.
That is one possible route to 10024. Others include a retry loop with no backoff, multiple EAs trading the same account, duplicate terminal or VPS instances, and logic that submits a new request before the earlier request's outcome has been resolved.
The first question is: what exactly is being repeated?
Start with the Experts and Journal tabs in the MT5 Toolbox. Examine timestamps around the first 10024 result. Identify the symbol, requested operation, EA instance, volume and stop values where the logs expose them.
A useful diagnostic log records the decision before the request, not just the rejection afterwards. For example:
- Why did the strategy decide to send a request?
- Was the intended order or stop level different from the last one?
- Was another request already pending?
- What did the trade server actually return?
When using CTrade , do not treat a successful method call as automatic proof of a completed trade. Inspect the result retcode and relevant transaction state. An accepted request, a completed deal, a rejected request and a request still being processed are not interchangeable.
The retry trap
Suppose an illustrative EA attempts to modify a stop. The server rejects the request. The program immediately retries, gets rejected again, and repeats on every tick.
Adding Sleep(1000) might slow the noise, but it does not answer the more important question: should this request be sent again at all?
A better design separates three decisions:
- Need: Has the desired trade state meaningfully changed?
- Validity: Is the proposed request valid for this symbol, account and current state?
- Permission to retry: Has the previous request reached a known outcome, and is another attempt justified?
If a retry is justified, use a bounded policy with logging and a controlled delay or backoff appropriate to the server and operation. Do not invent a broker-wide requests-per-second allowance. There is no universal cooldown guaranteed by error 10024.
Stop modifications deserve special suspicion
A trailing stop should not send a modification merely because OnTick() ran.
Compare the candidate stop with the existing stop, account for the symbol's tick size and price precision, and check relevant stop-distance and freeze-level constraints. A proposed change that is identical, invalid or too small to matter should not generate unnecessary server traffic.
Also remember that price normalization alone does not make a stop valid. The broker's symbol rules and the current Bid/Ask side still matter.
Your EA may not be alone
One EA can be perfectly polite while several instances collectively become a nuisance.
Check other charts, terminals and virtual-hosting environments. If you migrated an EA to an MT5 virtual server, verify which instances are actively trading. Check whether multiple EAs modify the same position, especially on netting accounts where positions are aggregated by symbol.
Do not assume a magic number creates an isolated server-side position. It is an identifier used by programs, not a private trading account.
A safer debugging workflow
First, if requests are still flooding, stop the offending automated execution safely and preserve the logs. Then reproduce the decision sequence on a demo account or in a controlled test environment.
Instrument the EA so each attempted request has a reason, a timestamp, a request identity or correlation key, and a recorded result. Ensure the program does not issue duplicates while an earlier request's status is unresolved.
Use the Strategy Tester to inspect the decision logic, but do not assume it reproduces a live broker's request-frequency controls. If the limit remains unclear, ask the broker for the applicable rules and provide non-sensitive timestamps and log excerpts.
Finally, distinguish 10024 from other failures. Error 10027 concerns automated trading disabled by the client terminal; 10030 concerns an invalid filling type. Changing filling policy will not fix a request flood, and enabling Algo Trading will not teach a retry loop manners.
The useful lesson
A reliable EA is not the one that sends the most instructions. It is the one that knows when not to send another.
Before adding another delay, another retry, or another hopeful click, find the event that caused the repeated request. Otherwise you may simply turn an aggressive robot into a slightly slower aggressive robot.
Educational discussion only. Correct request handling reduces avoidable technical failures; it does not make a trading strategy profitable or eliminate market risk.


