CFDs and forex are complex instruments and come with a high risk of losing money rapidly due to leverage. Risk disclosure

Closing Trades: Full Close, Partial Close and Close By

This guide explains how closing a position works in MetaTrader, how to close only part of it, and how each method changes your balance, equity and margin.

Extrade Pakistan editorial team ·

On this page
  1. What closing a trade means
  2. How to close a trade in MT5
  3. Partial close in MT5
  4. Close By: closing with an opposite position
  5. How closing affects margin
  6. Frequent questions

What closing a trade means

When you open a trade, you hold a position: a buy (long) or a sell (short) of a set volume in lots. To close a trade in forex or CFDs, you make the opposite deal for the same volume. A buy position closes with a sell at the bid price. A sell position closes with a buy at the ask price. See Long and short and Bid and ask.

Until you close, profit or loss is floating. It changes your equity but not your balance. At the close the result becomes realised and moves into the balance.

A position can close in these ways:

Leveraged CFD and forex trading can lose money fast. A close at market can also fill at a worse price than you saw because of slippage.

How to close a trade in MT5

In the MetaTrader 5 desktop terminal, open positions are listed in the Trade tab of the Toolbox window.

  1. Find the position in the Trade tab.
  2. Double-click it, or right-click it and choose Close Position. The order window opens.
  3. Check the volume and click the close button.

In the mobile app, you open the position from the trade list and choose Close. Menu names can differ slightly between terminal versions.

Partial close in MT5

A partial close closes only part of the position's volume. The rest stays open with the same entry price, stop loss and take profit.

  1. Open the order window for the position, as above.
  2. In the volume field, enter a smaller volume than the position holds.
  3. Click close.

The closed part is realised and moves to your balance. Traders use a partial close to lock in part of a result, or to cut exposure without leaving the trade entirely. The volume you close must fit the symbol's minimum volume and volume step. Check these in the contract specification in your terminal.

Close By: closing with an opposite position

MT5 accounts run in hedging mode or netting mode.

On a hedging account, Close By closes a position against an opposite position on the same symbol. Right-click a position, choose Close By, and select the opposite position. If the volumes match, both close. If they differ, the smaller volume closes fully and the rest of the larger position stays open.

The difference from closing each side at market: Close By settles the positions against each other, so you do not pay a spread on separate closing deals. Commission and swap already charged still count in the result.

How closing affects margin

Margin is the money the broker holds to keep a position open. See What is margin.

Action Used margin Balance Free margin
Full close Released for that position Changes by realised result Rises if margin was freed
Partial close Released for the closed part Changes by realised part Rises in line with the freed part
Close By (hedging) Depends on how the account charges hedged positions Changes by the combined result Depends on hedged margin rules

At the moment of the close, equity stays the same, because the floating result simply becomes realised. What changes is the margin in use, so free margin and margin level usually rise. Hedged positions may already carry reduced margin, so closing them can free less than you expect. Check the hedged margin rule in the contract specification. To work out results with your own numbers, use the calculators and Profit and loss.

You can practise every method on a demo account before you use real money.

Frequent questions

Does a partial close change my entry price?

No. The remaining volume keeps its original entry price, stop loss and take profit.

Why can't I see Close By in MT5?

Close By is only available on hedging accounts, and only when you hold an opposite position on the same symbol.

Is opening an opposite trade the same as closing?

On a netting account, yes: it reduces or closes the net position. On a hedging account it opens a separate position, and both stay open and keep using margin and swap until you close them.

Does closing a losing trade lower my equity?

No. The loss was already in equity as a floating loss. Closing moves it into the balance and releases margin.

Can a close fill at a different price than I clicked?

Yes. In fast markets the fill can differ because of slippage or price gaps. See Price gaps and Risk management.

Related pages