What Is a “Just-in-Time” (JIT) Liquidity Attack and How Does It Exploit the AMM Structure?

A JIT liquidity attack is a form of MEV where a bot detects a large trade in the mempool and quickly adds a large amount of liquidity just before the trade executes. This temporarily lowers the slippage and allows the large trade to execute at a better price.

Immediately after the trade, the bot removes the liquidity, capturing the trading fees generated by the large trade and the slight profit from the price change, all while exposing the liquidity for only a single block.

What Is “Just-in-Time” (JIT) Liquidity and How Does It Relate to Sandwich Attacks?
What Is a “Just-in-Time” (JIT) Liquidity Attack in the Context of Concentrated Liquidity?
What Is a “Sandwich Attack” and How Does It Exploit the AMM Structure?
What Are the Two Main Types of Trading Fees on a Crypto Exchange?
What Is the Difference between ‘Adding Margin’ and ‘Reducing Position Size’?
What Is a ‘Just-in-Time’ (JIT) Liquidity Provision Attack and How Does It Exploit Concentrated Liquidity Pools?
How Does ‘Just-in-Time’ (JIT) Liquidity Provision Affect Slippage?
What Is a ‘Just-in-Time’ (JIT) Liquidity Provision Attack on an AMM?

Glossar