Margin in forex trading refers to the collateral (good-faith deposit) that a broker sets aside from your account balance to open and maintain a leveraged position. Once you close the position, this margin is released back into your usable free margin.
Margin is required to maintain any leveraged trade. Each currency pair or asset has its own margin requirement percentage depending on your broker and leverage settings.
Used Margin refers to the total amount of money currently locked up by your broker across all of your open positions.
For example, to open a $1,000 (1 micro lot) position in EUR/USD with a 2% margin requirement (1:50 leverage), the Required Margin is $20. The broker temporarily sets aside $20 from your account equity to keep the $1,000 position open.
If you have $1,000 in your account and open that position requiring $20 in margin, $20 becomes your Used Margin and the remaining $980 is your Free Margin (available to open additional trades or absorb floating losses).
Similarly, if you open three positions that each require $20 of margin, then $60 (`3 × $20`) will be locked up to maintain all three positions—so your total Used Margin is $60.

What is Account Balance in Forex?
To start forex trading, you first open a live trading account with a broker and deposit funds. The total cash in your account from deposits, withdrawals, and closed (realized) trades is called your Account Balance.
Remember to verify your trading account with your broker before depositing funds, and only updates to closed positions (not open floating trades) change your Account Balance.

Floating P/L in Forex
Floating P/L stands for Floating Profit or Loss (also called Unrealized P/L). It is the real-time profit or loss on your currently open positions, which fluctuates with every market tick. Once you close the position, that floating profit or loss becomes realized profit or loss and is added to (or subtracted from) your Account Balance.
If your floating loss grows so large that your Margin Level falls to your broker’s stop-out level, the broker will automatically close your open positions to prevent a negative balance.
For example, suppose the current price of EUR/USD is 1.11000 and you buy a position size of 1,000 units (0.01 micro lot). After some time, the EUR/USD exchange rate rises to 1.12000.
Let’s calculate the unrealized (floating) profit/loss using the formula below:
Floating P/L = 1,000 units × (1.12000 − 1.11000) = +$10.00
The position is 100 pips in profit. Multiplying 100 pips by $0.10/pip (for a micro lot) gives +$10.00 in floating profit.
Once you close this position, that $10.00 becomes your realized profit and is added to your Account Balance.

Equity in Forex
Equity is the real-time value of your trading account, equal to your Account Balance plus (or minus) your total Floating P/L:
Equity = Account Balance + Floating P/L
If you have no open trades, your Equity is exactly equal to your Account Balance. When you have open trades, your Equity fluctuates on every tick along with your Floating P/L.
Difference Between Balance and Equity in Forex
The main difference between Balance and Equity is that Balance only reflects your closed trades, whereas Equity reflects the real-time value of your account including all currently open (floating) positions. Look at the diagram below for a clear summary:

I hope you found this article helpful. For any questions, comment below. You can also use TradingView for charting and technical analysis alongside MT4/MT5.
Note: All viewpoints here are for educational purposes based on technical analysis and risk management rules.