Skip to content
IntermediateLearn the steps

Exiting a position safely

Author
CRYPTO PORT Editorial
Published
Updated
Reading time
6 min

In short

Exiting a DeFi position is not finished when you sell. It is finished when you have withdrawn from wherever the assets were deposited, repaid any debt, claimed outstanding rewards and revoked the approvals. Since a falling market is exactly when the steps jam up, decide the order before you need it.

Key points

  • Exiting is several transactions, each costing gas and taking time
  • If you have borrowed, the debt must be repaid before collateral is released
  • It is only complete once you have also revoked the approvals
  • Congestion in a sell-off makes transactions hard to land, so plan the sequence in advance

Definition

The full sequence of actions that unwinds a DeFi position — liquidity provision, staking, lending or borrowing — and returns the assets to your own wallet or an exchange.

Start by writing down the shape of the position: which protocol holds what, in what form; whether you have borrowed; whether the share token is itself staked somewhere else; whether rewards are outstanding. Skip this inventory and you will run into a step that simply will not execute.

The ordering principle is outside in. If your share token is deposited somewhere, retrieve it first. Then claim any outstanding rewards. If you have borrowed, repay before touching collateral. Then withdraw from the pool or the stake, and finally revoke the approvals you no longer need. Get the order wrong and intermediate transactions fail, burning gas for nothing.

Positions involving debt need particular care. Trying to pull collateral out first degrades your health indicator, so the transaction is either rejected or, worse, pushes you toward liquidation. Line up the repayment asset first, complete the repayment, and only then touch the collateral. If you intend to fund the repayment by selling collateral, a mistake in sequencing can leave you stuck halfway.

Exiting during a sell-off has its own difficulty. Networks congest, fees rise and confirmations slow, and an exit made of several transactions accumulates all of that delay. On top of that, a thin token's price impact on the way out is larger than usual. Trying to clear the whole position in one action can fill far worse than you modelled.

The last step is revoking approvals. Closing a position does not remove the permissions you granted. Even with the assets back in your wallet, a live old approval means that the moment you fund that wallet again, someone can move it. Close the exit by reviewing the approval list and cancelling what you no longer use. Only then is the position actually unwound.

Watch out for

  • · Closing a position leaves the approvals in place. Continuing to use that wallet without revoking them keeps a route open for a later drain
  • · In a sell-off, congestion can stall a multi-step exit part-way through. Starting once you are already in danger may be too late
  • · Selling a thinly traded token all at once magnifies price impact and lands you at a far worse level than expected

Frequently asked questions

  • Should I unwind all at once or in parts?

    It depends. Splitting reduces price impact but multiplies transactions, gas and the time you remain exposed while working through them. The usual framing is: split when liquidity is thin, go at once when a sell-off is under way and cutting exposure fast matters most. Both have a cost.

Related coins

Read next

Crypto quizzes

Answer a few questions and get your result instantly.

Start