> For the complete documentation index, see [llms.txt](https://docs.flipsdex.trade/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flipsdex.trade/how-trading-works/liquidation.md). Agents can also search and read this documentation through its [MCP server](https://docs.flipsdex.trade/~gitbook/mcp).

# Liquidation

This page explains when the venue liquidates positions and how to estimate how far the price can move before it does. The venue runs liquidation, and FLIPS can't stop or reverse it.

## Margin requirements

Margin is the USDC that backs your positions. The venue sets three margin requirements for each market and measures them at the [mark price](https://docs.flipsdex.trade/how-trading-works/funding-and-prices.md#mark-price).

* Initial margin: what the venue requires before it accepts an order that opens or adds to a position. It equals the position value divided by your leverage.
* Maintenance margin: the minimum your account must hold to keep its positions. It equals the position value times the market's maintenance margin fraction.
* Close-out margin: a lower level than maintenance margin. Below it, the venue's liquidity pool takes over your positions.

Position value, also called notional value, is the position size times the mark price. Each market has one maintenance margin fraction, whatever the size of your position.

You set leverage per market, up to that market's limit. Until you change it, the venue's default for that market applies. See [Leverage and Margin](https://docs.flipsdex.trade/trading/leverage-and-margin.md).

Your account value is your USDC balance plus your unrealized profit and loss, the result so far on positions you haven't closed. The account panel on the Trade screen shows it as **Perp Equity**, along with **Maintenance Margin** and **Margin Ratio**.

With cross margin, your cross positions share one pool of margin, so a loss on one can lead to the liquidation of the others. An isolated position has its own margin, and the venue checks it on its own.

## Liquidation stages

The venue compares your account value with the three requirements and liquidates without warning. For an isolated position, it compares the position's own margin plus its unrealized profit and loss instead.

| Stage                   | Condition                                            | What the venue does                                                                                       |
| ----------------------- | ---------------------------------------------------- | --------------------------------------------------------------------------------------------------------- |
| Healthy                 | Account value at or above initial margin             | Accepts orders that keep the account at or above initial margin                                           |
| Pre-liquidation         | Below initial margin, at or above maintenance margin | Accepts only orders that reduce positions                                                                 |
| Partial liquidation     | Below maintenance margin                             | Cancels your open orders and closes positions on the Orderbook. Can charge a liquidation fee of up to 1%. |
| Full liquidation        | Below close-out margin                               | Its liquidity pool takes over your positions                                                              |
| Auto-deleveraging (ADL) | The pool can't absorb the loss                       | Closes positions of traders on the opposite side against the bankrupt position                            |

* In pre-liquidation, an order that would open or add to a position fails with a rejection message. FLIPS doesn't show the **Reduce-only market** notice for this account-level limit.
* If the venue cancels your FLIPS orders during a liquidation, **Order History** lists them as **Canceled** with the note "Cancelled while the position was liquidated."
* **Margin Ratio** in the account panel shows how close your account is to maintenance margin. See [Leverage and Margin](https://docs.flipsdex.trade/trading/leverage-and-margin.md).
* To move further from liquidation, reduce the position, deposit more USDC for cross positions, or add margin to an isolated position.

## Liquidation fee

The venue can charge a liquidation fee of up to 1% of the notional value of liquidation fills, and the fee goes to the venue's liquidity pool. FLIPS receives none of it and adds no FLIPS fee to fills that liquidate your positions. The liquidation fee is separate from the trading fee on [Fees](https://docs.flipsdex.trade/funds/fees.md).

## The liquidity pool and ADL

The venue's liquidity pool is a fund that takes over the positions of accounts below close-out margin. It divides its capital by market group.

Auto-deleveraging (ADL) is the venue's last step. If the pool can't absorb the loss of a bankrupt position, one that has lost more than its margin, the venue closes positions on the opposite side against it. ADL can close part or all of your position, including a profitable one, at a price you don't choose.

If one group's capital runs out, ADL can happen in that group while other groups still have capital. The venue doesn't publish an ADL rank for each position, so FLIPS doesn't show one.

## Example

This example estimates how far the mark price can move before an account reaches maintenance margin. It assumes:

* Cross margin, one long position and no open orders
* Account value: 1,000 USDC
* Position value: 10,000 USDC at the mark price
* Maintenance margin fraction: 3%, an assumption for this example. Each market has its own.

The numbers:

* Maintenance margin is 3% of 10,000, or 300 USDC. The gap to maintenance margin is 700 USDC (1,000 minus 300).
* Each 1% fall in the mark price costs the position 100 USDC (1% of 10,000) and lowers maintenance margin by 3 USDC (3% of that 100), so the gap shrinks by 97 USDC.
* 700 / 97 is about 7.2. After a fall of about 7.2%, the position has lost about 722 USDC and account value is about 278 USDC. Maintenance margin is 3% of the new position value of about 9,278 USDC, also about 278 USDC, so partial liquidation starts.
* A short position of the same size reaches maintenance margin after a rise of about 6.8% (700 / 103), because its maintenance margin grows as the price rises.

The example leaves out fees and funding, which also change your account value. For your own positions, use the liquidation price the app shows: **Liq Price** under the order buttons before you place an order, and the **Liq. Price** column in the **Positions** tab after it fills. Those prices use the market's own maintenance margin fraction, and with cross margin they also move with your other positions.
