> ## Documentation Index
> Fetch the complete documentation index at: https://docs.defiloops.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Order types

> Ways to place a trade beyond buying at the current price: wait for a level, break up a large size, protect a position, or buy on a schedule.

**In short:** you do not have to watch charts. A **stop** sells if the price falls through your level. A **trailing stop** follows the price up and sells when it turns, locking in the gain. A **limit** buys or sells only at your price. A **DCA** order buys the same amount on a schedule you pick, like every week. Once you set one, it runs on its own from your account.

Every trade here is the same swap underneath. What changes is *when* it runs and
*how* the size arrives. The swap page shows these as tabs; this page is what each
one does and when to reach for it.

They fall into five groups.

<Note>
  **One order, then it runs on its own.** Everything except a market swap rests
  against your account and fires unattended when its moment comes. Switching one on
  goes through the same checks as pressing Run. See [Running it without you](/automation).
  The self-signing wallet has no equivalent, so these appear only for your account.
</Note>

## Buy or sell now

### Market

<Frame caption="A market order swaps straight away, in one transaction, at whatever the price is.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/market.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=77080caffe0e50f83ada3319500975d2" alt="A market price line with the current price marked; a single fill lands on it labelled 'filled now'." width="760" height="470" data-path="images/orders/market.svg" />
</Frame>

A market order swaps now. You set how much price movement you will tolerate
between quoting and settling, and it takes the market as it stands, without
resting or waiting.

## Wait for a price

These rest until the market comes to a level you set, then run. Each rebuilds and
re-prices its swap at the moment it fires, so one can wait for days without going
stale.

### Limit

<Frame caption="A limit order rests until the market reaches your price, then fills there or at any better price.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/limit.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=eb7cae0ac46291b0558d9497852ad67f" alt="A price line drifting down to a dashed 'your price' level, where it fills." width="760" height="470" data-path="images/orders/limit.svg" />
</Frame>

Name the price you are willing to trade at, and wait. When the market gets there,
the order fills, at your price or at a better one if the book offers it. If the
price never arrives, nothing happens, which is a real answer rather than an error:
the price you asked for was better than the market.

### Rung

<Frame caption="A rung fills inside a band at your price and waits when the market runs past, instead of chasing it.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/rung.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=476e24c06d0af91210c3aedfac631c32" alt="A shaded band at a price level; the market fills while inside the band, and a 'waits — no chase' tag shows while it has run past." width="760" height="470" data-path="images/orders/rung.svg" />
</Frame>

A limit that refuses to chase. It fills only within a band at your price, and
when the market runs past the band it stops and waits rather than taking a worse
fill. The band is the same price-impact cap you would put on the swap, so a rung
trades *at* a level instead of sweeping through it. Set that cap on the trade
first, because a rung with no cap is refused.

### Stop

<Frame caption="A stop sells when the price falls through your level. The level is the trigger, and it sells at the market.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/stop.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=44774ffcb364f6c2ad2ff2b8de3aa519" alt="A price line falling through a red 'stop level'; a fill labelled 'sold at market' lands just below it." width="760" height="470" data-path="images/orders/stop.svg" />
</Frame>

Protection against a fall. When the price drops through your level, the order
fires and sells at the market. The level is the *trigger*, not a floor: once it
fires, it takes what the market gives, which may be a little below the line. Use
it to cap a loss without watching the screen.

### Trailing stop

<Frame caption="A trailing stop follows the price up and never falls back, firing when the market retreats to it.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/trailing.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=1c88c7111026b306e6eef1a50f3120b6" alt="A price rising to a peak while a dashed stop ratchets up beneath it, then the price retreats onto the stop and fires." width="760" height="470" data-path="images/orders/trailing.svg" />
</Frame>

A stop that ratchets up behind the price and never moves down. As the market
rises, the stop follows at the distance you set; when the market turns and falls
back to it, it fires. It locks in a gain that keeps growing while the price does,
without you moving the level by hand.

## Break up a large size

A large order against a pool that cannot absorb it in one go should arrive in
pieces. These three do that in different ways. (Whether splitting actually saves
money is a separate question. See [Splitting a big trade](/splitting).)

### Iceberg

<Frame caption="An iceberg is a limit that only ever shows a small slice at once, so the full size is never on the book.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/iceberg.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=32e21b47d2535d3922dd81c361c678db" alt="A tall faint bar marked 'your full size' with only a small bright slice visible at a time, filling in steps at a price level." width="760" height="470" data-path="images/orders/iceberg.svg" />
</Frame>

A limit for a size too large to reveal. It rests at your price like an ordinary
limit, but only a small slice is ever exposed at once; as each slice fills, the
next surfaces. The slice cap is the trade's price-impact bound, and partial fills
are always on, so the whole size never sits on the book advertising itself.

### TWAP

<Frame caption="A TWAP breaks the size into equal slices and fires one at the market each interval, over time.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/twap.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=708beb5aa5b1fc088470426a3fa15ab5" alt="Equal time intervals t1 to t6, each firing one slice at wherever the price is." width="760" height="470" data-path="images/orders/twap.svg" />
</Frame>

Spread the size over time. A TWAP cuts your order into equal slices and fires one
every interval, at the market, until it is done, so a large order lands as a
stream rather than a single print. It waits on the clock, not a price: each slice
is bounded by your slippage tolerance, not by a limit. Reach for it to get in or
out over a window regardless of where the price sits.

### Grid

<Frame caption="A grid lays a ladder of rungs across a price range and works the whole band as the price moves through it.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/grid.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=930c3abd8eaaa1a632e524619cbf9ced" alt="Evenly spaced rungs between a low and a high; the price oscillates and fills each rung it crosses." width="760" height="470" data-path="images/orders/grid.svg" />
</Frame>

For a price that is moving sideways. A grid spreads your size across evenly spaced
rungs between a low and a high you set. Each rung is a small rung order in its own
slice of the range, so the position builds across the whole band as the price
wanders through it, instead of committing at one price.

## Set an exit and a floor together

### Bracket

<Frame caption="A bracket places an entry with a take-profit above it and a stop below. A fill on one cancels the other.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/bracket.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=d584f5e559567465783b703292eb6ef7" alt="An entry level with a green take-profit above and a red stop below; the price fills the entry, reaches the target, and the stop cancels." width="760" height="470" data-path="images/orders/bracket.svg" />
</Frame>

Three orders in one. The entry buys at your price; a take-profit above it and a
stop below it both dispose of what the entry bought. The two protectors point at
the entry, so whichever fires first frees the other. You set an exit and a floor
in a single decision, and only one of them ever fires.

## Buy on a schedule

### DCA

<Frame caption="DCA buys the same size on a repeating schedule, whatever the price is that day.">
  <img src="https://mintcdn.com/defiloops/mWP0iuTzdQF8SI3V/images/orders/dca.svg?fit=max&auto=format&n=mWP0iuTzdQF8SI3V&q=85&s=b3e85154ac4930fc369dd53f3b65444c" alt="A clock and equal 'same size' buys at fixed intervals across days, regardless of the price line above them." width="760" height="470" data-path="images/orders/dca.svg" />
</Frame>

DCA is a standing arrangement rather than a resting order. The swap you set up is
saved and switched on as a schedule, and it buys the same size every interval
(daily, weekly, or whatever you pick), regardless of the price, until you switch it off. It is a [schedule](/automation),
so it fires unattended and is switched off from the schedules page rather than
cancelled like a resting order.

## They are all the same machine

None of these is a special contract. Underneath, each order is a trigger (a price,
a band, a trail or a clock) attached to an ordinary swap, and the trade that runs
is priced and approved at the moment it fires. That is why a new shape is a new
combination of the same parts rather than a new thing to trust, and why the price
floor on every fill is the same one enforced on the network for a swap you press
yourself.

<Note>
  Two neighbouring pages: [Sizing a trade](/routing) for how a size is chosen
  across pools, and [Bounds on a trade](/slippage) for the caps a rung and an
  iceberg reuse as their band and slice.
</Note>
