Choose cross or isolated margin

Selecting the right margin mode determines how your capital is allocated and where your liquidation risk sits. Onchain perpetual futures platforms generally offer two distinct options: cross margin and isolated margin. Your choice depends on your portfolio size, risk tolerance, and whether you want to hedge existing positions or trade aggressively with high leverage.

FeatureCross MarginIsolated Margin
Capital EfficiencyHigh. Uses entire wallet balance.Low. Uses only allocated funds.
Liquidation RiskDiffused. Harder to liquidate.Concentrated. Easier to liquidate.
Gas UsageHigher. Frequent rebalancing.Lower. Fixed margin amount.
Best Use CaseLong-term holders, hedgers.Short-term speculation, high leverage.

Cross margin treats your entire wallet balance as collateral for your open positions. If the price moves against you, the platform can draw from your other assets to prevent liquidation. This mode offers higher capital efficiency because you don't need to lock up large amounts of capital in a single position. However, it increases the risk of losing your entire portfolio balance if the market moves sharply against you. It is best suited for traders who hold diversified portfolios and use perpetuals for hedging rather than pure speculation.

Unknown component: SourceLink

Isolated margin assigns a specific amount of capital to each position. If the position is liquidated, you only lose the allocated margin, not your entire wallet balance. This mode offers precise risk control but requires more active management and higher gas costs due to frequent margin adjustments. It is ideal for traders who want to limit their downside exposure or use high leverage on short-term trades.

onchain perp margin

For most onchain traders, isolated margin is the safer starting point. It forces discipline by capping your losses to a known amount. As you gain experience and better understand funding rates and liquidation prices, you can transition to cross margin for more efficient capital deployment.

Select a low-fee perp DEX

Platform fees and gas consumption erode your margin efficiency before a trade even settles. Choosing the wrong venue turns a profitable setup into a net loss. The goal is to minimize friction costs—trading fees, funding rates, and transaction gas—while maintaining sufficient liquidity to execute your position size.

Start by comparing the fee structures of major on-chain perpetual futures platforms. Look beyond the advertised "maker" fees; taker fees and funding rate spreads often matter more for active traders. A platform with zero trading fees might charge higher funding rates, which drains your margin over time. Conversely, a platform with low funding might charge steep taker fees that hurt scalpers. Calculate the total cost of holding and trading on your intended time horizon.

Next, evaluate the gas costs associated with your chosen blockchain. Trading on Ethereum mainnet can consume significant capital in gas fees, especially during high network congestion. Consider layer-2 solutions or alternative L1s where gas is negligible. The difference between paying $5 and $50 in gas per trade compounds quickly. Use a PriceWidget to contextualize current asset prices, helping you gauge the relative impact of fixed gas costs against your position size. Finally, verify liquidity depth. Low-fee platforms often suffer from thin order books, leading to high slippage. Slippage is a hidden fee that can wipe out your margin advantage. Check the order book depth for your specific trading pair. If the spread is wide or the book is shallow, no amount of fee reduction will save your trade. Prioritize venues that balance low costs with deep liquidity to protect your capital.

Set up your position parameters

Opening a position on an onchain perpetual exchange requires precise configuration of your margin mode and leverage. Unlike traditional finance, where collateral is often locked in a centralized custodian, onchain trading demands that you manage your own wallet connection and smart contract approvals. Getting these parameters right before you click "Open Position" is the difference between a clean trade and a liquidated one.

Follow this sequence to configure your trade efficiently.

onchain perp margin
1
Connect your wallet

Start by connecting your Web3 wallet to the exchange interface. Ensure you are on the correct network (e.g., Solana, Ethereum, or Arbitrum) that the perpetual contract supports. Most onchain DEXs will prompt you to sign a message to authenticate your identity without moving funds. Verify the network status page of the protocol to avoid connecting to the wrong chain, which can lead to failed transactions or loss of access to your collateral.

onchain perp margin
2
Select margin mode

Choose between Isolated Margin and Cross Margin. Isolated margin assigns a specific amount of collateral to a single position, limiting your risk to that allocated portion. Cross margin uses your entire available wallet balance as collateral for all open positions. For beginners managing risk, isolated margin is often safer because a liquidation event in one trade will not drain your entire account balance. Check the exchange’s documentation to understand how your specific platform calculates maintenance margin requirements for each mode.

onchain perp margin
3
Set your leverage

Leverage amplifies both gains and losses. A 10x leverage means your position size is ten times your collateral. While high leverage can increase efficiency, it significantly raises the risk of liquidation. Most onchain platforms allow you to adjust leverage dynamically, but setting it at the outset is critical. Start with conservative leverage (e.g., 3x–5x) to understand how price fluctuations impact your margin ratio. Remember that higher leverage requires tighter stop-losses and more frequent monitoring.

onchain perp margin
4
Confirm transaction details

Before finalizing, review the total position size, estimated funding rate, and liquidation price. Onchain transactions require a gas fee (or transaction fee) to execute the smart contract interaction. Ensure you have enough native token (e.g., ETH, SOL) in your wallet to cover this fee, separate from your trading collateral. Click "Open Position" and sign the transaction in your wallet. Wait for the block confirmation; once confirmed, your position will appear in your open positions tab, and you can begin monitoring your margin efficiency.

Monitor funding rates and liquidation

Active margin management requires two parallel tracks: watching the cost of carry and tracking the distance to liquidation. Ignoring either metric turns your position into a ticking clock.

Watch funding rate shifts

Funding rates are periodic payments between long and short traders that keep the perpetual price close to the spot index. When the rate is positive, longs pay shorts; when negative, shorts pay longs [src-serp-1].

High positive rates signal excessive bullish leverage. If you are long, these payments erode your margin over time. If rates spike above 0.1% per 8 hours, your daily holding costs can exceed trading profits. Consider reducing size or switching to isolated margin to contain the risk.

Set liquidation buffers

Liquidation happens when your margin balance drops below the maintenance threshold. In cross margin, this drains your entire wallet balance; in isolated margin, it only risks the allocated amount [src-serp-1].

Set your stop-loss or take-profit orders to trigger before the liquidation price. A common rule is to keep liquidation at least 20% away from your entry price. This buffer absorbs normal volatility without forcing a forced close.

Use cross vs. isolated strategically

Cross margin uses all available wallet balance as collateral, lowering liquidation risk but exposing your entire account to a single trade. Isolated margin limits loss to the specific amount allocated, protecting the rest of your funds.

Use isolated margin for high-volatility trades where you want to cap downside. Use cross margin only for low-leverage positions where you want to minimize margin calls [src-serp-1].

Monitor liquidation price closely

Your liquidation price changes as the market moves and as funding rates adjust your margin balance. Most platforms update this value in real time.

Set price alerts at your liquidation level. If the price approaches within 10% of liquidation, prepare to add margin or close the position. Never wait for the platform to notify you—by then, the liquidation may already be executing.

Common margin mistakes to avoid

Even with advanced tools, small errors in onchain perp margin efficiency can trigger liquidations or drain profits through fees. The most frequent mistakes involve over-leveraging, ignoring gas spikes, and failing to monitor pool liquidity.

Over-leveraging positions

Using maximum leverage leaves no room for price volatility. A 50-basis-point move against a 100x position wipes out the entire margin. Keep leverage conservative relative to the asset's volatility.

Ignoring gas spikes

Onchain transactions require gas, which fluctuates based on network congestion. Executing margin calls or rebalancing during a gas spike can consume more value than the trade itself. Always check gas prices before interacting with DEXs.

Underestimating slippage

Low-liquidity pools suffer from high slippage, meaning your entry or exit price deviates significantly from the quoted rate. This erodes margin efficiency faster than expected. Avoid trading thin pools during high-volatility periods.

onchain perp margin

Final checklist for efficient trading

Before opening a position, verify your margin mode. Cross margin shares your balance across all positions, while isolated margin limits risk to a single trade. Choose the mode that matches your current risk tolerance.

onchain perp margin

Run through these steps to ensure your trade is set up correctly:

During the trade, monitor funding rates and liquidation prices closely. These factors can quickly erode your margin efficiency if left unchecked.

Frequently asked: what to check next

What is margin in onchain perp trading?

Margin is the collateral you lock to open and maintain a perpetual futures position. It acts as a buffer against price volatility; if losses eat into this buffer below the maintenance threshold, the position liquidates. You can use isolated margin (risking only the allocated amount) or cross margin (using your entire wallet balance), as outlined in MetaMask’s guide on margin types [src-serp-1].

What is 20x leverage on $100?

20x leverage on $100 gives you $2,000 in buying power. However, this amplifies risk: a 5% move against you wipes out your entire $100 principal. Onchain swaps require careful calculation of liquidation prices to avoid total loss, as detailed in educational resources on leverage mechanics [src-serp-3].

Is onchain perp trading profitable?

Profitability depends on risk management, not just leverage. High leverage increases the probability of liquidation during volatile markets. Most traders lose money due to funding rates and fees. Success requires strict stop-losses and understanding that high leverage is a tool for hedging or short-term speculation, not guaranteed income.

How do I optimize margin efficiency?

To optimize margin efficiency, avoid over-leveraging. Use isolated margin for speculative trades to cap losses. Monitor funding rates to avoid paying excessive fees for long-term positions. Always keep extra collateral in your wallet to prevent accidental liquidation during sudden market swings.