Fix exchange, bot and MT5 order errors
Find your error: a plain-English meaning, the three usual causes, a short fix you can run, the current limits for popular symbols with their official source, and a small calculator. 15 errors from Binance, OKX, Bybit, Kraken, Coinbase, ccxt and MetaTrader 5.
Binance
- Filter failure: LOT_SIZE
Binance rejected your order because the quantity is too small, too large, or not a whole number of steps for that symbol. - Filter failure: NOTIONAL
Binance rejected the order because price x quantity (its notional value) is outside the allowed range for that symbol. - Filter failure: PRICE_FILTER
Binance rejected your limit or stop price because it is too high, too low, or not a whole number of ticks. - Parameter 'quantity' has too much precision.
Binance error -1111 (BAD_PRECISION) means a number you sent has more decimal places than the symbol allows. - Order's notional must be no smaller than 5.0 (unless you choose reduce only)
On Binance USD-M futures, error -4164 means price x quantity is below the minimum order value.
OKX
- Order quantity must be a multiple of the lot size.
OKX error 51121 means the size (sz) you sent is not an exact multiple of the instrument's lot size (lotSz). - Your order should meet or exceed the minimum order amount.
OKX error 51020 means your order is smaller than the instrument's minimum size (minSz).
Bybit
- Order quantity lower than the minimum.
Bybit error 170136 means the quantity of a spot order is lower than the symbol's minimum order quantity.
Kraken
- EOrder:Order minimum not met
Kraken answers EOrder:Order minimum not met when the volume of your order is below the ordermin of that pair. - EOrder:Cost minimum not met
Kraken answers EOrder:Cost minimum not met when price x volume is below the pair's costmin, the minimum order value in the quote currency (0.5 USD on XBTUSD in our data)..
Coinbase
- INVALID_SIZE_PRECISION
Coinbase returns INVALID_SIZE_PRECISION when the order size has more decimal places than the product's base increment allows.
ccxt
- binance amount of BTC/USDT must be greater than minimum amount precision of 0.00001
ccxt raises this InvalidOrder before it even talks to the exchange.
MetaTrader 5
- TRADE_RETCODE_INVALID_VOLUME (10014): Invalid volume in the request
MetaTrader 5 returns retcode 10014 when the lot size in your order request breaks the symbol's volume rules: below SYMBOL_VOLUME_MIN, above SYMBOL_VOLUME_MAX, or not a multiple of SYMBOL_VOLUME_STEP.. - TRADE_RETCODE_INVALID_STOPS (10016): Invalid stops in the request
MetaTrader 5 returns retcode 10016 when a stop loss or take profit is too close to the current price (inside SYMBOL_TRADE_STOPS_LEVEL), on the wrong side of the price, or has an invalid price step.. - TRADE_RETCODE_INVALID_FILL (10030): Invalid order filling type
MetaTrader 5 returns retcode 10030 when the type_filling you put in the order request is not allowed for that symbol and its execution mode.
Check this automatically before every order: AIKIT (free 1,000 calls)
Disclosure: AIKIT is our own product.
General information for education only. It is not financial advice, and trading can lose money.