Understanding Ethereum Flashbots and onchain arbitrages

If you are following the Ethereum DEX and recent community updates you might have come across the terms MEV (Maximum extractable value or Miner extractable value ) , Front running …etc. For a layman these terms can be quite intimidating but it is important to understand this as it is also a store of great arbitrage opportunities. Apart from this, knowing what front running is and how the mempool is flooded with bots in gas auctions can help you build a more clear picture of Ethereum Blockchain.

How transactions work ?

When you do any kind of transaction on the Ethereum Blockchain network, it is first sent to a node and then broadcasted to the whole network (or a large part of it). During the time a transaction is broadcasted and not entered into the actual Blockchain, it resides in a queue called Mempool. This is where everything happens during front running.

Bots front running you !

The Ethereum Blockchain doesn’t just consist of simple transactions but it can also involve complex multi chain swaps , a crypto kitty smart contract ..etc. All of these are essentially “Transactions” on the Ethereum Blockchain and when your transaction is on Mempool on hold to be included in the next block , some bots will quickly analyze what the result of the transaction would be. If it finds out that any of the transactions is giving a +ve ROI to the sender (like you solving a puzzle and getting paid Ether from a smart contract) , a bot will run the transaction on their own and direct the proceeds to themselves. Your transaction will get uploaded in Blockchain but it won’t give you the desired result as the contract would have been already emptied out by the bot.

How big is the front running ?

There is a huge market for this kind of frontrunning and it is estimated that only in 2021 about $300M was collectively earned through front running. At times when one bot loses to another and is unable to retract the transaction, the transaction fees (gas) is spent and cumulatively around $6M of fees was lost in such a manner in 2021. There have been many random tests performed in order to check how fast these bots are brought into action and almost all of them suggest that if you have a vulnerable transaction then chances are that most likely you would be attacked.

Conclusion

The front running exists and is ever increasing in the Ethereum network. Due to high activity on DEX (Decentralized exchanges) arbitrage opportunities due to multi transaction swaps or sometimes even by simple typo exists. Hence, we as users need to be aware of this risk and understand that this not only affects high value transactions but the bots are programmed in a way to profit from any profitable transaction.

Disclaimer: This material should not be taken as the basis for making investment decisions, nor be construed as a recommendation to engage in investment transactions. Trading digital assets involve significant risk and can result in the loss of your invested capital. You should ensure that you fully understand the risk involved and take into consideration your level of experience, investment objectives and seek independent financial advice if necessary.