// Use case

Front-run the frontrunners
with faster data.

MEV bots extract millions from Solana traders every month by exploiting slow data feeds. They see your transaction, sandwich it, and pocket the difference — all because they had faster access to on-chain state. Subglow gRPC streams give you the same speed advantage: sub-5ms transaction delivery so you can detect sandwich patterns, avoid frontrun-heavy tokens, and route through Jito bundles with real-time intelligence.

The MEV problem on Solana

Maximal Extractable Value (MEV) has become one of the most significant hidden costs of trading on Solana. Unlike Ethereum where MEV operates through a public mempool, Solana MEV bots exploit the network's high throughput and deterministic transaction ordering to extract value from ordinary traders. Every swap you make on Jupiter, every token you buy on Pump.fun, and every liquidity position you open on Raydium is visible to sophisticated bots that can act on that information faster than you.

Conservative estimates put MEV extraction on Solana at over $30 million per month. Much of this comes directly from retail traders' pockets — widened spreads, failed transactions, and unfavorable fills that could have been avoided with better data and faster execution.

Sandwich attacks

The most common MEV strategy. A bot detects your pending swap, places a buy order for the same token immediately before yours (driving the price up), then sells immediately after your transaction executes at the inflated price. You pay more, the bot pockets the spread. On high-volume tokens, a single sandwich can cost you 2-5% of your trade value.

Frontrunning

Bots with faster data feeds see your transaction the moment it hits a validator. They analyze the expected market impact, then submit their own transaction with a higher priority fee to execute first. By the time your trade confirms, the price has already moved against you. This is especially devastating on low-liquidity Pump.fun tokens where a single buy can move the price 10-20%.

Backrunning

After your large trade shifts the market price, backrun bots immediately execute arbitrage trades to capture the price dislocation you created. While this doesn't directly worsen your fill, it means you're subsidizing bot profits with every significant trade. Backrunning bots are the most common MEV extractors on Solana, accounting for roughly 60% of all MEV activity.

Slippage exploitation

When you set a high slippage tolerance (common on volatile memecoins), MEV bots see this as an invitation. They can manipulate the price up to your slippage limit, knowing your transaction will still execute. Traders who set 10-15% slippage on Pump.fun tokens regularly lose the full slippage amount to bots that engineer the exact price movement to drain maximum value.

How fast data protects you

MEV protection isn't about blocking bots — it's about having the same information they do, at the same speed. When you can see every transaction as it confirms, you can detect MEV patterns and make smarter execution decisions. Here's how Subglow's real-time gRPC streams change the equation.

01

See transactions as they confirm — not after polling delay

Standard RPC polling checks for new transactions every 1-5 seconds. In that window, MEV bots have already analyzed, sandwiched, and profited from your trade. Subglow streams deliver every confirmed transaction within 5ms of slot finalization. You see the same data MEV bots see, at the same speed, giving your execution logic the real-time context it needs to make informed decisions.

02

Detect sandwich patterns in real-time

With every Pump.fun buy, Raydium swap, and Jupiter route streaming to your bot as structured JSON, you can monitor for classic sandwich signatures: a large buy on your target token from an unknown wallet, followed by unusual sell pressure within the same slot window. When your bot detects these patterns, it can delay execution, switch tokens, or adjust routing — all before submitting a transaction.

03

Route through Jito bundles with computed tips

Jito bundles let you submit transactions that execute atomically, preventing bots from inserting trades between yours. But optimal bundle tips change with network conditions. Subglow streams give you real-time transaction volume and fee data so you can compute the minimum effective tip — not overpaying during quiet periods or underpaying during congestion. Better tip calculation means higher bundle inclusion rates and lower costs.

04

Execute with minimal slippage using live price data

Instead of setting a static slippage tolerance and hoping for the best, your bot can use Subglow's real-time swap data to calculate the current effective price for any token pair. Dynamic slippage — adjusted per-trade based on live liquidity depth and recent price volatility — removes the excess slippage that MEV bots exploit. Tighter slippage means less room for bots to profit.

MEV detection events

Subglow streams every transaction across Pump.fun, Raydium, and Jupiter as pre-parsed JSON events. Here are the patterns your bot can monitor to detect and avoid MEV extraction in real-time.

PatternSignalWhat it means
Rapid buy → buy → sell on same tokenSandwichTwo buys from different wallets in the same slot, followed by a sell from the first wallet. Classic sandwich pattern targeting the second buyer.
Large buy immediately before pool createFrontrunA bot detects an upcoming Raydium pool creation and buys the token on Pump.fun before liquidity is added, securing a lower entry price.
Identical token buys from known MEV walletsMEV clusterMultiple known MEV wallets buying the same token within a narrow time window indicates coordinated extraction activity on that token.
Unusual Jupiter routing with high priority feesPriority frontrunA swap using an atypical Jupiter route with an abnormally high priority fee suggests a bot paying to ensure its transaction lands before yours.
Sell immediately after your buy confirmsBackrunA wallet sells the same token within 1-2 slots of your buy, capturing the price impact your purchase created. Persistent backrunning erodes returns over time.

Protection strategies

Real-time data alone doesn't stop MEV — it's what you build with it. These are the four core strategies that Subglow users implement to minimize MEV losses. Each one relies on sub-5ms event delivery to function effectively.

MEV-aware execution

Before submitting any trade, your bot checks the Subglow stream for recent sandwich activity on the target token. If a known MEV wallet has bought the token in the last few slots, or if there's an unusual volume spike from non-organic wallets, the bot flags the token as actively sandwiched and either delays execution, reduces position size, or skips the trade entirely. This alone can eliminate 80% of sandwich losses.

Jito bundle optimization

Jito bundles are the strongest protection against sandwich attacks, but overpaying tips erodes your margins while underpaying means bundles don't land. By streaming real-time transaction data from Subglow, your bot can track current tip levels across the network and compute the optimal tip for each bundle. During low-activity periods, a 0.0001 SOL tip suffices; during congestion, you scale dynamically. The result: higher inclusion rates at lower average cost.

Dynamic slippage guards

Static slippage settings are MEV magnets. A 10% tolerance on a Pump.fun token tells bots they can extract up to 10% of your trade value. With Subglow streams, your bot calculates real-time liquidity depth for each token by analyzing recent swap volumes and pool sizes. Slippage is set per-trade: tight on deep liquidity pairs, slightly wider on thin markets — but never more than the current market conditions warrant.

Backrun detection and adjustment

Backrunning is harder to prevent than sandwiching, but it can be detected and accounted for. By monitoring the Subglow stream after your trade confirms, your bot can identify wallets that consistently sell immediately after your buys. Over time, this builds a profile of active backrunners on your target tokens. Your bot can then adjust position sizing, use limit orders instead of market orders, or split large trades across multiple slots to reduce backrun profitability.

Frequently asked questions

What is MEV on Solana and how does it affect my trades?

MEV (Maximal Extractable Value) refers to the profit that bots can extract by manipulating the ordering of transactions within a block. On Solana, MEV bots monitor pending transactions and insert their own trades before or after yours to profit at your expense. Common MEV strategies include sandwich attacks, frontrunning, and backrunning. These attacks cause you to receive worse prices, higher slippage, and can turn profitable trades into losses.

How does real-time gRPC data help protect against MEV?

Traditional RPC polling introduces 200-500ms of delay, giving MEV bots a massive window to analyze and exploit your transactions. Subglow gRPC streams deliver transaction data in under 5ms after slot confirmation, allowing you to detect suspicious patterns — like rapid successive buys on your target token — before submitting your trade. With real-time data, you can identify sandwiched tokens, route through Jito bundles, and adjust slippage dynamically based on current liquidity conditions.

What are Jito bundles and how do they prevent sandwich attacks?

Jito bundles allow you to submit a group of transactions that execute atomically — either all of them land in sequence, or none do. This prevents MEV bots from inserting transactions between yours. By combining Subglow real-time stream data with Jito bundle submission, you can compute optimal tips based on current network conditions and ensure your transactions land without being sandwiched.

Can Subglow detect sandwich attacks in progress?

Yes. Subglow streams every confirmed transaction with pre-parsed event data including token addresses, wallet addresses, and transaction amounts. Your bot can monitor for classic sandwich patterns — such as a large buy on a token immediately followed by another buy from a different wallet, followed by a sell from the first wallet — all in real-time. When these patterns are detected on your target token, you can delay or reroute your trade.

How much does MEV protection cost with Subglow?

MEV protection is built on Subglow's standard gRPC infrastructure. Any plan with access to filtered streams gives you the data needed to implement MEV detection and avoidance strategies. Plans start at $99/mo with sub-5ms event delivery, pre-parsed JSON data, and persistent gRPC connections.

Stop being the exit liquidity.

Real-time MEV detection starts with real-time data. Sub-5ms streams, pre-parsed events, Jito-ready intelligence.