OKX DEX FAQs

Published on Mar 11, 2023Updated on Nov 21, 20246 min read35

Why does a transaction fail?

  • When there's network congestion, for example, on the Ethereum network, the network fee could rise sharply. When you don't have enough balance to pay such a fee, the transaction may fail.

  • Some tokens require a certain level of slippage tolerance when being swapped at a DEX to make sure the transaction goes through. For example, if a token requires a slippage tolerance at 3% but you set it at 1% when swapping the token, this transaction may fail.

  • When the market fluctuates, the level of liquidity will also change. When the total transaction amount is lower than the minimum receiving amount, the contract will stop the transaction, causing it to fail.

  • When a user submits multiple similar transactions but the balance is only enough for one, all the others submitted after that will fail.

How to speed up a transaction?

When you initiate a transaction on Ethereum or other EVM networks, your network fee (also known as the gas fee) is for using the network, which is paid to miners or validators who process your transaction. If you choose a lower level of network fee for your transaction, it may take a longer time to process. There's also a possibility of network problem that'll cause your transaction to stuck and make you wait for a long time. At OKX DEX of the OKX Wallet, you can choose how fast you want to have your transaction processed by modifying the network fee for contract interaction from a slower Gwei to an average or fast Gwei. You can also maintain the slow Gwei fee and continue to wait for the network to process the transaction, or reject the contract interaction and wait for the average network fee to drop before proceeding with it.

CT-mobile-dexfaq-1

Select Network fee to set the speed of the process

Do I still need to pay network fees when a transaction fails?

When you send/transfer tokens and interact with contracts, or perform other activities on the blockchains, you must pay network fees to miners or validators for processing the transactions. Miners or validators must compute the network resources consumed during transaction processing. As a result, you're required to pay the fee regardless of whether the transaction succeeds or fails. This fee isn't charged by the wallet, so we can't refund it. Therefore, we don't recommend choosing a low level network fee to save money because it might lead to transaction failure or blockage. If the transaction is blocked, you need to pay another transaction fee to eliminate the blockage, making this an unfavorable trade.

How to check the price of purchased tokens?

  1. Launch the OKX app and switch to OKX Wallet

  2. Select Trade, before selecting the three horizontal dots menu to prompt a selection of options

  3. Select Transaction history

  4. Select any of the crypto to enter its details page, for example ETH → WETH, and you'll see that 0.001 ETH was swapped to 0.001 WETH, and the network fee was 0.001746 ETH

    CT-mobile-dexfaq-2

    Select Transaction history to view the list of purchased tokens and their price

Why is the token price displayed in the wallet inconsistent with the price executed on a transaction?

What's slippage? How does it impact the price?

If a token price is different from the price executed in a transaction, it's likely due to slippage. Slippage is the difference between the expected price of a trade and the price at which the trade is executed. Due to the varying levels of liquidity of each platform, traders often face the risk of losing assets because of the slippage. For example, if you initiate an ETH purchase order on DEX, you expect the transaction to be executed at the selected price. But when the transaction is complete, if the final price is higher or lower than the price you selected when placing the order, it means you've encountered slippage.

Slippage is an implicit cost that is unavoidable for most transactions, especially on DEXs. Slippage is especially prominent in times of market volatility or insufficient liquidity of trading platforms. The more often you experience slippage, the more money you lose.

How to avoid slippage?

Slippage can't be completely avoided, but the losses caused by slippage can be reduced. First, only trade on platforms with good liquidity and well-established infrastructure. Also, it's best to choose assets with high trading volume and high liquidity. In addition to that, instead of placing a large order directly, you can choose to trade in a smaller volume that's easier to close. If your order amount exceeds the existing liquidity, DEX can't execute the transaction. If a large order is split into several small ones, they're more likely to go through as it reduces the chances of insufficient liquidity. Next, set the maximum slippage. When the actual amount you'll receive is smaller than the amount by the maximum slippage setting, the transaction will be canceled to prevent losses. OKX DEX is a one-stop multi-chain and cross-chain aggregation trading platform. Through the X Routing algorithms, OKX DEX automatically calculates the optimal transaction path and splits orders, providing users with the best quotes with lower slippage and lower network costs.

Why do some tokens have higher slippage?

Some tokens require a high slippage, such as SafeMoon, which is used for the buyback of liquidity pool tokens, crypto burning, and for incentivizing token holders. With such tokens, OKX DEX has launched automated slippage to help users improve the success rate of transactions with optimal slippage.

Where does OKX DEX get the prices of tokens?

OKX DEX, with the X Routing algorithms, automatically finds the on-chain liquidity pools with the best depth, intelligently splits orders, and thoroughly calculates quotes, slippage, and network fees, thereby providing the optimal path for transactions.

Find out more about DEX here.