Trading
Margin and leverage
Collateral, equity, free margin, initial and maintenance margin.
Margin is cross: one USDC balance backs every position and resting order in every market, and a profit in one market counts as margin in another.
The account
The account panel on the trade screen and the account summary in the API show the same figures:
| Figure | What it is |
|---|---|
| Collateral | Deposits and faucet claims, plus realized PnL and funding, minus fees and withdrawals. |
| Equity | Collateral plus the unrealized PnL of open positions at the mark price. |
| Initial margin | For each position, its notional divided by the leverage you set for that market. |
| Maintenance margin | 2.5% of each position's notional. |
| Free margin | Equity minus the initial margin of positions and resting orders, never below zero. |
| Leverage used | Total notional of positions divided by equity. |
Initial margin
Leverage is set per market from 1x to 20x. An order is accepted only if free margin covers its initial margin, its notional divided by that leverage. A 10,000 USDC order at 5x needs 2,000 USDC of free margin.
Maintenance margin
Maintenance margin is 2.5% of notional, half the initial margin at 20x, whatever leverage the position uses. The 10,000 USDC position above carries 250 USDC of maintenance margin. When equity falls below the account's maintenance margin, the engine liquidates.
Free margin and withdrawals
Free margin is what a new order can use and what a withdrawal can take. A withdrawal larger than free margin is refused.