> ## Documentation Index
> Fetch the complete documentation index at: https://docs.magna.so/llms.txt
> Use this file to discover all available pages before exploring further.

# How To Defund A Contract

> Withdraw tokens from a Claim (escrow) smart contract back to your admin wallet.

Defunding a contract withdraws tokens from a **Claim (escrow) contract** back out of the contract. You can withdraw a specific amount, or leave the amount empty to withdraw the entire available balance.

<Note>
  Defund applies to **Claim** contracts only, and only when the contract has a balance greater than zero. [Direct Transfer](/admins/product-guides/smart-contracts/contract-types) contracts have no escrow balance to withdraw.
</Note>

## Defund a contract

1. Go to **Settings → Token Distribution → Smart Contracts** and select the token.
2. On the Claim contract's card, click **Defund**.
3. In the **Defund Smart Contract** dialog, enter the **Amount** to withdraw — or leave it empty to withdraw the entire available balance. The dialog shows the current balance available to withdraw.
4. Click **Create**.

Magna prepares a **Defund Contract** transaction and takes you to the transaction details.

## Sign the defund transaction

1. Go to the **Transactions** tab.
2. Sign the **Defund Contract** transaction with your admin wallet.

Once it confirms on-chain, the withdrawn tokens return from the contract and the contract's **Balance** updates.

<Warning>
  Withdrawing tokens reduces the balance stakeholders can claim against. Make sure the remaining balance still covers any tokens that are already unlocked and expected to be claimed.
</Warning>
