What It Does
Some validators are known to sandwich or otherwise exploit the transactions they receive. With MEV protection on, Apex skips leaders on the Shield blocklist when it forwards your transaction. The transaction waits for a leader that is not on the list rather than being handed to one that is. The blocklist is an on-chain Yellowstone Shield policy, so it is public and auditable.The Trade-Off
A leader produces 4 consecutive slots, about 1.6 seconds. When a blocklisted leader is up, a protected transaction waits out its turn. Make sure your blockhash has time left, and do not use protection as a substitute for a sensible slippage limit.
How to Enable It
MEV protection is set per transaction over HTTP, and per connection over QUIC.
In the samples below,
TX_BASE64 and the apex-tx helper come from Sending transactions.