Long liq price
Long net distance (% drop)
Short liq price
Short net distance (% rally)
80% partial-liq threshold (long)
90% partial-liq threshold (long)
Tool guide · formulas · common mistakes

How to use this tool

The actual "leverage number" on an OKX perpetual isn't the multiple shown in the top-right of the chart — it's the percentage distance from entry to liq price. At 20x with MMR 0.4%, the long liq distance is about 4.6%, the short about 5.4%; the asymmetry comes from the direction term in the formula. The calculator runs OKX's exact equation and shows the numbers in concrete USDT.

Worked example: BTC long at 60,000, 20x, MMR 0.4%. Liq price ≈ 57,240 — about 4.6% drop. Flip to short at 60,000 and liq price ≈ 62,760 — also about 4.6% adverse move. Bump leverage to 50x: long liq rises to 58,880 (about 1.87% drop), short liq drops to 60,960 (about 1.6% rally). At 50x the trade effectively means "BTC moves 1.6% the wrong way and the margin is gone".

OKX doesn't fully liquidate at one shot — it first triggers "partial liquidation" at 80% of the path to liq, then again at 90%. The tool prints both thresholds so your stop-loss doesn't sit right on top of them.

The math behind it

Long liq price  = Entry × (1 - 1/L + MMR)
Short liq price = Entry × (1 + 1/L - MMR)

Long distance  = 1/L - MMR
Short distance = 1/L - MMR

80% partial-liq (long) = Entry - 0.8 × (Entry - liq)
90% partial-liq (long) = Entry - 0.9 × (Entry - liq)

MMR on OKX is tier-based, not flat: larger positions sit in higher tiers with higher MMR and lower allowed max leverage. BTC at small notional has MMR around 0.4%; a 5M USDT position sits above 2% and the resulting liq price degrades materially. This tool holds MMR constant, which is fine for typical retail sizing.

Common mistakes

"Liq price is fixed by entry and leverage." Not quite. OKX triggers liquidation off the mark price, not the last trade. Mark is an index plus smoothed funding premium — in extreme conditions the on-screen "BTC price" can show 57,500 while mark has already touched 57,240 and liquidated you.

"My stop-loss sits above liq, so I'm safe." Not necessarily. A stop-loss is a limit or market order. In a flash crash with thin liquidity, the order can simply not fill — price punches through your stop and lands on liq. BTC's 2024-08-05 flush invalidated a large number of stop orders.

"Partial liquidation sounds like a gentle warning." Partial-liq does reduce the chance of full liquidation, but it does so by market-closing a meaningful chunk of your position — if price reverses afterward, you can't get it back. It's emergency deleveraging from OKX, not a buffer.

Done with the math? Cross-check on the OKX order ticket.

OKX's order panel shows a live liq price next to every position — the value matches the formula here to within rounding. Sign up via referral code OK6512 and the OKX Affiliate fee rebate applies*.

Sign up on OKX (OK6512)

*Actual rebate percentage moves with OKX Affiliate policy. This site is not OKX-affiliated except via the referral code.