Margin Calculation
The standard margin requirement is calculated by summing an account’s margin requirement for its perpetual and option positions and then adding the value of its cash balance and base assets (with haircut). For each market, the margin is calculated as follows:Formula
Perp Marginis the margin requirement for all perpetuals in the account, calculated as a simple percentage of the underlying’s spot price. The profit and loss of said perpetuals, as well as owed/owing funding is included in this value.Option Marginis the margin requirement for all options in the account, typically calculated as the sum of isolated margin for each option, with the possibility for margin offsets for spreads and other multi-legged strategies within the same expiry.Depeg Contingencyis extra initial margin conditionally required to protect against the cash asset depegging.Oracle Contingencyis extra initial margin conditionally required to protect against inaccurate oracle data feeds.Cashis the subaccount’s balance of the universe’s cash asset (which can be positive or negative)Collateralis the value of the base assets held (or borrowed) in the subaccount, after a risk based haircut.
Maintenance Margin is negative (see Liquidations for more details) and a sub-account is only able to open a new position if its final Initial Margin is positive. See the end of this page for more detail on this and risk reducing trades.
[New!] Collateral
Collateral is credited by a multiplicative haircut factor. This is a change of convention from V2, which subtracted a discount; the two express the same thing, but the V3 factor is the fraction of value that counts, and it is exactly themarginFactor configured on chain.
Formula
Baseₘis the account’s balance of base assetm, positive if held and negative if borrowed.MM_HAIRCUTₘis the long factor, always< 1. BTC is0.75, i.e. 1 BTC at contributes 75,000 towards maintenance margin.IM_HAIRCUTₘ = MM_HAIRCUTₘ x imScaleₘis the long factor used for initial margin, always at or below the maintenance factor. BTC is0.6975.MM_SHORT_HAIRCUTₘ/IM_SHORT_HAIRCUTₘare the short factors, always> 1. BTC is1.3for maintenance, i.e. borrowing 1 BTC at 100,000 requires 130,000 of margin.Spotₘis the spot price of base assetm.
The cash asset
The universe’s cash asset carries a row of the same shape, so the quote is a configurable currency like any other. At launch USDC ships with a factor of1.0 long and short: cash counts at face value and borrowing it carries no haircut beyond the interest rate. Protection against the cash asset losing its peg is handled separately, by the depeg contingency below.
Perpetuals Margin
All perpetuals have margin requirements proportional to the spot price. This percentage is larger when computing initial margin, and is set per currency:Formula
Sizeis the number of perpetual contracts (this number is negative for shorts).perp_im,perp_mmare per-currency requirements —0.066/0.05for BTC and ETH,0.1/0.08for HYPE,0.2/0.15for ADA.Spotis the spot price of the underlying base asset.
Option Margin
Options are typically margined in isolation, with the exception of spreads and multi-legged strategies whose margin requirements can be offset for the same expiry. The option margin for an account is the sum of each expiry’s margin, which is calculated by grouping positions per expiry, summing their isolated margin and offsetting spreads and multi-legged strategies where possible. Options with different underlyings (ETH, BTC) are margined separately and then added together. I.e. the option margin of all ETH options is found, then added to that for all BTC options to get the total option margin for the subaccount. In the following, we focus on computing the option margin for a single underlying; the option margin for a subaccount with multiple underlyings is easily found given this.Isolated Margin
The isolated margin of an option for strike pricej is calculated as follows:
For long calls and puts:
Formula
Formula
Formula
nis the number of short options heldOTMis the out-the-money amount. For calls,OTM = max(0, Strike - Spot)and for puts,OTM = max(0, Spot - Strike).Spotis the spot price of the underlying base asset.Strikeⱼis the strike of the option.Mark Priceis the mark-to-market value of the option calculated using Black76, discounted at the expiry’s risk free rate. Since the option is short, this is a negative quantity.- For BTC and ETH,
(maxSpotReqCall, minSpotReqCall, mmCallSpotReq) = (0.15, 0.13, 0.09)and(maxSpotReqPut, maxStrikeReqPut, mmPutSpotReq, mmPutStrikeReq) = (0.15, 0.13, 0.09, 0.09).
📘 [New!] Short put requirements are now anchored to the strike. In V2 the put floor was a flat percentage of spot. In V3 the initial margin takes the larger of a spot-based and a strike-based leg, and the maintenance margin takes the smaller of the two. For a deep out-of-the-money put where the old spot leg could fall to nothing the strike leg keeps the requirement meaningful; for a deep in-the-money put the maintenance requirement is capped by the spot leg.
📘 [New!] Option marks are discounted. Standard margin now prices options with the expiry’s risk free rate rather than assuming zero discounting. A negative rate feed is clamped to zero, so it margins identically to a zero rate.
Expiry Margin
The default margin of expiryi is calculated by summing the isolated margin of each option in the account for that expiry:
Formula
i to offset spreads and other multi-legged strategies. This is made up of 2 components:
- The minimum intrinsic value of the expiry’s options evaluated at all strikes in with this expiry (including the zero strike), floored at 0.
- A percentage of the expiry’s forward price multiplied by the number of “naked” short calls in the expiry.
Formula
Formula
Intrinsic Valueᵢis the intrinsic value of all options in the expiry evaluated at each strikekfor expiryi(including the zero strike).Naked Short Call Sizeᵢis the number of naked short call contracts open in the expiryi.Forward Priceᵢis the forward price for the expiryi.UNPAIRED_SCALE_IM = 1.2scales naked short calls for initial margin requirements.UNPAIRED_SCALE_MM = 1.1scales naked short calls for maintenance margin requirements.
i is then the better (larger) of the default expiry margin and offset expiry margin:
Formula
Default Initial Margin and Offset Initial Margin are negative, so the above takes the more lenient margin requirements for the trader.
[New!] Settled Expiries
Once an expiry has settled, its value is fixed at the settlement TWAP and it carries no remaining spot risk. Neither the isolated percentage-of-spot requirement nor the spread scenario search applies, i.e. both explore spot moves that can no longer happen. The requirement is simply the realized payoff, floored at zero:Formula
Total Margin
Finally, the total option margin for an account is the sum of each expiry’s margin:Formula
Depeg Contingency
When the cash asset depegs from $1, additional initial margin requirements are added:Formula
Cash Asset Valueis the market value of the universe’s cash asset.Spotis the spot price of the underlying base asset.Short Option Sizeⱼis the absolute number of contracts for a short option with strikejin the account.Perp Sizeis the number of perpetual contracts (this number is negative for shorts).depeg_threshold = 0.99is the threshold value that triggers a depegging event.depegFactor = 2.0scales the depeg contingency.
📘 When the cash asset’s value (reported by oracle data feeds) is greater than the depegging threshold, the depeg margin requirement is $0.
Oracle Contingency
Associated to each oracle data feed is a confidence score; a metric for the feed’s reliability and accuracy. When confidence scores are below a given threshold, this indicates the data feeds could be feeding inaccurate price data into the system, and the protocol automatically introduces additional initial margin requirements. The oracle contingency is the sum of collateral, perpetual and option oracle contingencies:Formula
Formula
Formula
Formula
OCFactor = 1.0is a constant scaling factor.Short Options Sizeis the number of short options contracts for the relevant feeds, i.e. long options are not charged.Perp Sizeis the number of perpetual contracts open in the account.Spot Confidenceis confidence score of the spot price data.Forward Confidenceis confidence score of the forward data.Vol Confidenceis confidence of the implied volatility data.Perp Confidenceis confidence of the perpetual price data.oc_collateralThreshold = oc_perpThreshold = oc_optionThreshold = 0.55represent the thresholds at or below which extra initial margin is added due to low confidence.
Open Interest Caps
Each universe caps the open interest, spot supply and spot borrow of every instrument its standard manager supports.Risk Reducing Trades and Risk Assessors
On the smart contract level, the standard risk manager will allow any trade to be conducted so long as it satisfies either of the following conditions:- the initial margin of the portfolio after the transaction is conducted is positive (
IM(post) > 0) OR - the trade is risk reducing
- Adds a long option
- Adds a positive amount of the cash asset
- Adds base collateral
- Closes a perpetual
Examples
All examples below are in the Prime universe, which hosts BTC and ETH.Example 1: A simple short call
ETH is trading at $1900. Account:- $2000 of USDC
- 3.0 short ETH 1800 calls expiring in 3 weeks, mark price 120 per call.
Formula
OTM = max(0,1800-1900)=0.
Formula
Formula
Example 2: A short put (new put logic)
ETH is trading at $2000. Account:- $2500 of USDC
- 2.0 short ETH 2400 puts, mark price 430 per put.
OTM = max(0, 2000 - 2400) = 0. For initial margin we compare the two legs:
Formula
Formula
Formula
Formula
Example 3: Spread Logic
Account:- $2000 of USDC
- 8 x SHORT $1700 ETH calls expiring in 2 weeks
- 8 x LONG $1900 ETH calls expiring in 2 weeks
Formula
Formula
Thus, we have
Formula
Formula
Formula
Example 4: Multi Asset Account with a Borrow
Account (Prime universe):- $25,000 USDC
- 0.5 BTC held as collateral
- 5.0 ETH borrowed
- 8 x SHORT 1700 ETH calls / 8 x LONG 1900 ETH calls expiring in 2 weeks
- 0.3 x LONG BTC perpetuals (with no unrealized PNL or funding)
Formula
Formula
Formula
Formula
Formula
Example 5: General Case
Consider the same subaccount as in example 4, but now assume:- The confidence of the BTC perp feed decreases to 0.50 (below the threshold of 0.55) and
- The market price of USDC depegs to $0.70.
Formula
Formula
Formula
