TWAP orders
A TWAP order buys or sells a size in equal market orders, one every 30 seconds, over a running time you choose. Use it to trade a large size without taking the whole book at once.
On this page: How it works
A TWAP runs on the exchange itself. Once placed, it keeps going when you close Mirrorlane, until its running time ends or you cancel it. Pick TWAP under Advanced on the ticket.
How it works
Section titled “How it works”Every 30 seconds the exchange sends one market order, a slice. The slices are equal: your size divided by the number of slices, which is the running time divided by 30 seconds, plus one.
Each slice fills against the book as any market order does, at the prices the book offers when it goes, and never past your price limit if you set one. Without one, the slices have no price limit of your own.
Before you send, the order details show the order’s value at the mid price, the number of slices, when it finishes in UTC, and the margin it takes at your leverage.
Settings
Section titled “Settings”| Setting | What it does |
|---|---|
| Size | The total to buy or sell. Each slice is an equal share of it. |
| Duration | 15 min, 30 min, 1 hour (the default) or 4 hours. Or type any running time from 5 minutes in Minutes. |
| Highest or Lowest | Optional. No slice fills above this price on a buy, or below it on a sell. |
| Reduce only | Off by default. Slices only make your position smaller. |
Each slice pays the fee of a market order. See The fee.
What can go wrong
Section titled “What can go wrong”- The price runs past your limit. Slices don’t fill past it, so the order can end with less than its full size filled.
- The book is thin. Each slice takes what the book offers when it goes, so a large slice in a quiet market fills at worse prices than the best one.
- Your position closes during a reduce-only TWAP. It keeps running until its time is up, and trades only when a slice takes the position toward zero.
- You reach the pending order limit. A TWAP counts as one pending order. Plus accounts hold up to 500 and Premium up to 1,000, with at most 100 in one market.
- The exchange is at its TWAP cap. The exchange limits how many TWAPs run at once, and refuses a new one at the cap: “Too many TWAP orders are running on the exchange right now. Try again later.”
Check on it or cancel it
Section titled “Check on it or cancel it”The TWAP table shows each running TWAP: how much has filled, its average price, the next slice and when it ends. Fills from its slices gather in one notice. Cancel stops the slices still to come; what has filled stays filled.
TWAP or Advanced TWAP
Section titled “TWAP or Advanced TWAP”Advanced TWAP runs in your browser instead: a slice as often as every 5 seconds, a passive, neutral or aggressive style, and randomized slices. It stops when you close the last Mirrorlane tab.
Updated