What is a "sandwich attack," and how can I check if I’ve been attacked?

A sandwich bot attack is a common malicious trading tactic that occurs on-chain. It typically involves high-frequency trading bots (often called sandwich bots) that quickly buy or sell tokens to capitalize on price discrepancies. These bots may engage in front-running transactions or manipulate gas fees to complete transactions before regular users, allowing them to profit from price changes.You might be a victim of a sandwich bot attack if you notice the following signs:

  1. Significant Price Difference: The actual price of your transaction differs greatly from the price just a second earlier.

  2. Coinciding Transactions: There’s a buy and a sell transaction right before and after your trade, both originating from the same address.

  3. Bot Mark: Your transaction address is marked as a bot on DEXTOOLS.

  4. Typical Trade Amounts: The amounts being traded by the bot usually fall between $6,000 and $9,000.

  5. Your Transaction Type: Your transaction is a buy order.

If your trade doesn’t meet these criteria, it's likely that you weren't attacked by a sandwich bot, but rather that someone else made a trade ahead of you, driving the price up.To protect yourself from these attacks, you can activate the "MEV protection" in DEXX, which can help prevent this risk.

Last updated