Advanced Swap Queue & Limit Swaps
The Advanced Swap Queue is one of the most important upgrades to THORChain this year. It replaces simple, linear swap processing with intelligent, price-aware scheduling that can match trades far more efficiently.
At its core, this system is powered by three execution mechanisms: Rapid Swaps, Limit Swaps, and Streaming Swaps. Working together, they transform THORChain from a passive swap router into an active execution engine. The protocol can now match opposing flows, execute trades at predefined prices, and complete swaps rapidly, all at the base layer.
In this article, we focus on Limit Swaps and the Advanced Swap Queue, which together lay the foundation for orderbook-like behaviour on THORChain.
Note: Rapid Swaps were covered in a previous article.
🤔What Is the Swap Queue and Why Does It Exist?
Every swap on THORChain doesn’t execute immediately. It first enters a Swap Queue, a core feature designed for fair execution and MEV protection.
On most blockchains, validators can reorder transactions to profit from price movements. THORChain removes this risk entirely. Swaps are not ordered by arrival time or node preference. Instead, the protocol scores each swap based on the fees it generates, which are determined by slippage. Swaps with higher slippage produce higher fees, so they are processed first. Nodes cannot change this order; they simply execute the queue as defined by consensus.
This makes frontrunning unprofitable. To jump ahead in the queue, an attacker would need to submit a swap with even greater slippage, costing more in fees than they could gain.

While the original Swap Queue provided security and fairness, it only supported a single type of swap. As the network evolved, greater flexibility was required, leading to the Advanced Swap Queue.
More info : https://docs.thorchain.org/thornodes/frequently-asked-questions#how-does-thorchain-prevent-mev
📈From Swap Queue to Advanced Swap Queue
The Advanced Swap Queue is a major upgrade to THORChain’s core engine. Instead of executing them in a simple linear order, the queue now supports multiple swap types, evaluates trades in relation to each other, and can process multiple iterations within a single block.
This allows THORChain to behave like a dynamic pricing engine while still using AMM liquidity pools as its execution layer.
👉And because it is built into the base layer, every wallet, DEX, or frontend integrating THORChain automatically benefits from these features.
The Advanced Swap Queue supports three core swap types:
🔸Market Swaps and Streaming Swaps🔸
Market swaps are the default option for users who want execution at the current price. They are processed immediately, and if the output falls below the user’s minimum acceptable amount, the swap is refunded.
Market swaps are typically executed as Streaming Swaps, meaning the trade is split into smaller parts to reduce slippage and allow pools to rebalance between each execution for better price efficiency.
🔸Limit Swaps and Streaming Limit Swaps🔸
Limit Swaps let users set the exact price they want for a trade. Instead of being refunded if the price isn’t met, the swap stays in the queue and waits until the target price is reached. These swaps are persistent, cancellable, and execute automatically once conditions are satisfied.
For larger trades, limit swaps can be executed as Streaming Limit Swaps. Rather than filling the entire trade in a single transaction (which may cause significant slippage on large trades) the order is split into smaller parts and executed gradually at the target price.
👉 This preserves price control while improving execution efficiency.
🔸Rapid Swaps🔸
Rapid Swaps are not a separate user-facing swap type, but an execution path within the Advanced Swap Queue. They allow the protocol to process multiple swap iterations within a single block. When opposing flows are available, trades can be instantly matched and netted, enabling far more swaps to be executed per block.
👉This significantly improves speed, throughput, and price execution, enhancing the overall user experience.

🎓Limit Swaps Simplified
Limit Swaps introduce a powerful capability to THORChain: the ability to trade at a specific price in a fully native and decentralised way, without relying on external orderbooks or smart contracts. Here’s how they work:
1️⃣ A user submits a Limit Swap with a defined target price. It enters the Advanced Swap Queue and waits.
2️⃣ With every block, the protocol checks whether the pool price meets the user’s target.
3️⃣ If the price condition is met, the swap is executed, often using streaming to fill the trade gradually for optimal price execution. If not, the swap simply remains in the queue.
👉Limit Swaps are secured directly by the THORChain protocol. When submitted, funds are held in THORChain’s decentralised vaults, controlled collectively by the node network until the trade is executed or expires.
Each Limit Swap has a default Time-to-Live (TTL) of around three days. If the price is not reached within that timeframe, any unfilled amount is automatically returned to the user.
🆙 How Limit Swaps Improve Arbitrage and Price Stability
👉Today, arbitrageurs react to price drift.
They wait for the pool price to move away from the external market, then submit a Market Swap to correct it. This reactive approach introduces a delay, allowing prices to disconnect temporarily and exposing users to poor price execution.
👉With Limit Swaps, arbitrage becomes proactive.
Arbitrageurs can place orders directly into THORChain at specific prices. When the pool price reaches that level, the swap is executed automatically by the protocol. This means arbitrage is ready before price movement occurs, not after.
This creates a self-correcting system where:
🔹Prices stay aligned with global markets.
🔹Swaps execute faster.
🔹Slippage is reduced for all users.
🔹Arbitrageurs no longer need to monitor and react, they can be proactive.
🙌 Rapid + Limit + Streaming Swaps = Orderbook-Like Execution
When combined, Limit Swaps, Streaming Swaps, and Rapid Swaps deliver execution similar to a centralised orderbook, while still relying on AMM liquidity underneath.
When a Limit Swap reaches its target price, it does not wait for future blocks to process. The protocol can immediately break the trade into multiple segments (Streaming Swaps) and execute them within the same block using Rapid Swaps. This allows even large trades to be filled quickly and efficiently, without causing significant price impact.
👉Users benefit from the precision of limit orders, the slippage protection of streaming, and the speed of rapid intra-block execution.
This marks THORChain’s evolution into an on-chain order engine, one that intelligently matches flows, maintains tight pricing, and delivers high-speed execution while remaining fully decentralised.
⚙️A New Trading Engine for THORChain
Limit Swaps, Streaming Swaps and Rapid Swaps mark a fundamental transformation in how THORChain operates.
What was once a simple swap router is now evolving into a real-time execution engine that adjusts prices dynamically, matches flows intelligently, and processes trades within a single block.
By embedding these capabilities at the base layer, THORChain boosts performance, reduces slippage, increases throughput, and enables proactive arbitrage. Traders gain precision, nodes see higher volume, and all stakeholders benefit from higher revenue.
With these upgrades, THORChain is no longer just a cross-chain AMM, it is laying the foundation for a fully decentralised, on-chain order engine that rivals centralised exchanges in execution quality while preserving the trustless and permissionless nature of L1s.