> For the complete documentation index, see [llms.txt](https://help.rails.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.rails.xyz/trading/options/margin-and-liquidation.md).

# Margin & Liquidation

{% hint style="info" %}
You can find all calculations in our [Options Metrics Guide](/trading/options/options-metrics-guide.md).
{% endhint %}

## Margin

Margin treatment on Rails depends on whether you are **long** or **short** an option contract. Long options are paid for upfront, so your maximum loss is known when the trade opens. Short options can become riskier after the trade opens, so they stay subject to ongoing margin checks.

Because the risk profiles differ, long and short options use different margin models:

<table><thead><tr><th width="130.64453125">Position type</th><th width="190.8828125">Margin model</th><th width="180.8984375">Ongoing monitoring</th><th>Liquidation treatment</th></tr></thead><tbody><tr><td>Long Calls &#x26; Long Puts</td><td>Premium plus buffer, locked at entry</td><td>No maintenance threshold</td><td>Maximum loss is fixed at the premium paid</td></tr><tr><td>Short Calls &#x26; Short Puts</td><td>Initial Margin and Maintenance Margin</td><td>Continuously monitored</td><td>New short exposure can be restricted, and the position can be liquidated, as the margin ratio rises</td></tr></tbody></table>

### Long options

When you buy a call or a put, your maximum loss is known at entry: it is limited to the **premium paid**. For that reason, long options do not use a maintenance threshold.

Rails locks the premium plus a small buffer as margin. The buffer covers costs that may apply if the position must be closed — a liquidation fee, an insurance fee, and slippage. This margin is returned to your account at expiry or when you close the position.

{% hint style="info" %}
See the long-option margin formulas in the [Metrics Guide](/trading/options/options-metrics-guide.md).
{% endhint %}

### Short options

Short calls and short puts can lose **more than the premium received**, so collateral is monitored continuously after the trade opens. Short options use two margin thresholds:

<table><thead><tr><th width="180">Threshold</th><th>What it means</th></tr></thead><tbody><tr><td><strong>Initial Margin (IM)</strong></td><td>The margin required to open the position. (roughly 15% of the index price, with floors and an out-of-the-money discount).</td></tr><tr><td><strong>Maintenance Margin (MM)</strong></td><td>The minimum margin required to keep the position open. (roughly 5% of the index price, with floors and an out-of-the-money discount).</td></tr></tbody></table>

Short-option margin is based on the market value that drives the risk:

* **Short calls** are margined against the **index price**, because a rising market has no ceiling — losses can keep growing as the underlying climbs.
* **Short puts** are margined against the **strike price**, because the underlying can only fall to zero, so the strike bounds the maximum risk.

As a result, short margin is **not fixed**. Required margin moves with the market because it depends on the current price and premium. As the market moves against you, a short position can require more margin and move closer to liquidation.

{% hint style="info" %}
IM and MM apply only to short options. See [Initial Margin (Short Call or Short Put)](/trading/options/options-metrics-guide.md#initial-margin-short-call-or-short-put) and [Maintenance Margin (Short Call or Short Put)](/trading/options/options-metrics-guide.md#maintenance-margin-short-call-or-short-put) for the exact formulas.
{% endhint %}

#### Risks of short options

{% tabs %}
{% tab title="Short Calls" %}
Short calls carry **unlimited risk**. If the underlying rises sharply, losses can keep expanding with no ceiling.

For that reason, Rails checks that the position has enough collateral both at entry and throughout the life of the trade. Liquidation is assessed at the account level, based on your total equity (your balance plus unrealized P\&L) compared with your maintenance margin — not position by position. If your account falls below the maintenance requirement, Rails reduces or closes at-risk short positions to bring the account back within limits.
{% endtab %}

{% tab title="Short Puts" %}
Short puts carry **large, bounded risk**. The underlying can only fall to zero, but the distance between the current price and zero can still be significant.

For that reason, margin is measured against the strike price and checked at entry and throughout the trade. Liquidation is assessed at the account level, based on your total equity (your balance plus unrealized P\&L) compared with your maintenance margin — not position by position. If your account falls below the maintenance requirement, Rails reduces or closes at-risk short positions to bring the account back within limits.
{% endtab %}
{% endtabs %}

<details>

<summary>Why the strike for short puts, but the index price for short calls?</summary>

For a **short put**, the seller's maximum risk is bounded by the strike — the asset can only fall to zero. For a **short call**, there is no ceiling, so risk scales with the current market price. Each side is margined against the value that captures its worst case.

</details>

#### OTM Discounts on short positions

When a short option is out of the money, it is less likely to be exercised against you, so Rails applies an **out-of-the-money (OTM) discount** that reduces the required margin. The further out of the money the option is, the larger the discount. As the market moves toward the strike, the discount shrinks and the required margin rises back toward its full risk-based level.

The OTM discount lowers short-option margin when the strike is further from the index price. As the option moves closer to the money, the discount gets smaller and required margin increases.

{% columns %}
{% column width="41.66666666666667%" %}
Calls and puts use different OTM discount formulas because OTM is measured in different directions for each option type.

The discount is applied inside both short-option margin formulas, but the mark-price floor still sets a minimum margin requirement.
{% endcolumn %}

{% column width="58.33333333333333%" %}
{% hint style="info" %}
See the exact formulas in the [Options Metrics Guide](/trading/options/options-metrics-guide.md):

* [Initial Margin (Short Call or Short Put)](/trading/options/options-metrics-guide.md#initial-margin-short-call-or-short-put)
* [Maintenance Margin (Short Call or Short Put)](/trading/options/options-metrics-guide.md#maintenance-margin-short-call-or-short-put)
* [OTM Discount (Call)](/trading/options/options-metrics-guide.md#otm-discount-short-calls-puts)
* [OTM Discount (Put)](/trading/options/options-metrics-guide.md#otm-discount-short-calls-puts)
  {% endhint %}
  {% endcolumn %}
  {% endcolumns %}

## Liquidation

Rails continuously monitors open short-option positions and their effect on your margin ratio. The goal is to stop unrealized losses from eroding your collateral too far. Long options do not use a maintenance threshold, so this monitoring applies only to short exposure.

Two points on the **margin ratio** (used margin ÷ total equity) matter most:

<table><thead><tr><th width="146.984375">Margin Ratio</th><th>Account Status</th></tr></thead><tbody><tr><td>85% – 90%</td><td>Approaching liquidation; new short positions cannot be created. Long trades that fit within your available margin are still allowed.</td></tr><tr><td>≥ 98%</td><td>Liquidation triggered; positions are liquidated immediately.</td></tr></tbody></table>

{% hint style="info" %}
A liquidation fee may apply. See [Pricing & Fees](/trading/options/pricing-and-fees.md) for more information.
{% endhint %}

#### How positions are liquidated

When an account reaches the liquidation threshold, Rails closes positions in a defined order designed to relieve risk as efficiently as possible, using [the Greeks](/trading/options/black-76-and-the-greeks.md#the-greeks) to sequence liquidation priority. **Short positions are liquidated first**, starting with short calls, because reducing short exposure lowers risk faster than closing long positions.

Within short positions, Rails sequences liquidation by risk:

<table><thead><tr><th width="86.828125">Order</th><th width="212.03515625">Measure</th><th>Why</th></tr></thead><tbody><tr><td>1st</td><td>Largest <a href="/pages/rFy02RjAy9r2qkWRiWkK#the-greeks">Delta</a></td><td>Biggest directional exposure.</td></tr><tr><td>2nd</td><td>Highest <a href="/pages/rFy02RjAy9r2qkWRiWkK#the-greeks">Gamma</a></td><td>Most unstable; risk accelerates fastest.</td></tr><tr><td>3rd</td><td>Nearest Expiry</td><td>Decay is fastest and gamma is highest.</td></tr><tr><td>4th</td><td>Remaining positions</td><td>Residual clean-up, including long positions only if still required.</td></tr></tbody></table>

After each position is closed, Rails recalculates your margin ratio. If closing a position brings you back below the threshold, liquidation stops there and your remaining positions stay open.

{% hint style="success" %}
**Long positions are a last resort.** They carry limited risk and can help offset exposure, so they are only closed as emergency clean-up if liquidating your short positions has not restored your account.
{% endhint %}

#### Avoiding liquidation

To reduce liquidation risk on short positions:

* Deposit funds to increase your available balance and lower your margin ratio.
* Reduce or close short exposure to lower the margin required.
* Monitor positions closely when the underlying is moving toward your strikes, since required margin can rise quickly when the market moves against you.
