Reference · Market Mechanics
Free Margin and Margin Level Explained
Distinguish free margin from margin level with an account-state calculation, zero-margin edge cases and checks for changing equity and costs.
Published Updated
Published by FxTrusts, a supplier of brokerage and prop firm technology. Prepared with AI-assisted research and drafting; reviewed against the cited public sources. Examples are illustrative. Product links describe our services.
Quick answer
Free margin is generally equity minus used margin. Margin level is generally equity divided by used margin, multiplied by 100%. One is an amount of money; the other is a ratio. Confirm the platform’s account model and treatment of credits, costs and open profit or loss.

Read the same account in two different ways
Free margin answers how much equity remains after the stated margin requirement. Margin level compares equity with that requirement. An account with 8,000 USD equity and 2,000 USD used margin has 6,000 USD free margin and a 400% margin level under the simple model. Those are not alternative names for the same number. Display both units clearly when presenting an operations dashboard or responding to an account query.
Use current equity, not only the cash balance
Open profit or loss can change equity without changing the posted balance. Commission, financing, credit or blocked amounts may also affect an account’s available values. The MetaTrader account documentation describes these fields and their configuration dependencies. If a user reports that free margin changed without a deposit or withdrawal, compare the equity components and margin requirement at the relevant times before treating it as a ledger error.
Handle the zero-denominator case deliberately
When used margin is zero, equity divided by margin is undefined. A platform may display a blank value, a special indicator or another documented representation. Do not convert this into an arbitrary numeric percentage in a report. Free margin can still be meaningful when no margin is used. Test an empty account, a funded account with no positions and an account whose positions have just been closed to check the transition.
Do not turn a ratio into an approval guarantee
A high margin level does not by itself prove that a proposed order will pass every check. Quantity limits, permissions, instrument status, pending orders and the incremental margin model can still prevent execution. Conversely, the warning and close-out actions associated with a low ratio depend on account terms. An operations worksheet should record the observed values and threshold configuration without assigning a universal safe percentage.
Equity changes while used margin stays fixed
The following synthetic account has 2,000 USD used margin throughout. Costs and any changes to the margin requirement are omitted to isolate the effect of equity. The final row shows a separate zero-margin state; its percentage should be treated as not applicable rather than calculated by dividing by zero.
| Equity | Used margin | Free margin | Margin level |
|---|---|---|---|
| 8,000 USD | 2,000 USD | 6,000 USD | 400% |
| 5,000 USD | 2,000 USD | 3,000 USD | 250% |
| 2,400 USD | 2,000 USD | 400 USD | 120% |
| 5,000 USD | 0 USD | 5,000 USD | Not applicable in this formula |
Implementation checklist
- Keep monetary free margin separate from percentage margin level.
- Capture equity and used margin from the same account-state timestamp.
- Document special handling when used margin is zero.
- Check the actual threshold and pre-trade policies before interpreting the ratio.
Sources
These documents support the reference. Check the original publication for current requirements and the limits of its scope.
- MetaTrader 5 executing trades and account valueswww.metatrader5.com
- MQL5 account propertieswww.mql5.com
- MetaTrader 5 margin calculationwww.metatrader5.com
Continue with the broader guides
Connect this reference to platform selection and the wider operating workflow.
