All articles

Empty token accounts on Solana: where they come from, how much SOL they lock and how to close them safely

Every memecoin you have ever held leaves a token account with a SOL deposit behind. We explain what that costs according to the Solana docs, when an account can be closed, what a burn does and why “reclaim your SOL” sites can be a trap.

Guide9 minSwaps and costs, part 4 of 4By Published
Editorial illustration: Empty token accounts on Solana: where they come from, how much SOL they lock and how to close them safely
MEMECOINY editorial illustration

Key takeaways

  • On Solana a token balance lives in a separate token account, and every account must hold a refundable SOL deposit sized by its data
  • By the documented formula, a regular token account (165 bytes) locks 2,039,280 lamports, about 0.00204 SOL. A Token-2022 account is larger and locks more
  • An account can be closed only once its token balance is zero. The whole deposit goes to the destination address you choose
  • A burn permanently reduces the balance and the supply. It is how you get rid of leftover tokens before closing the account
  • A delegate can transfer or burn tokens up to a set allowance. Revoke removes it, but a Token-2022 permanent delegate cannot be revoked
  • A “reclaim SOL” site asks you to sign a transaction. Check that it only closes accounts and burns, and that the destination is your own wallet

What a token account is and why you have so many[2]

On Solana a wallet does not hold tokens directly. Each token balance sits in a separate account, a token account, tied to your address and a specific mint. The default one is the associated token account (ATA): according to the Solana docs its address is derived from the wallet address, the token program address and the mint address, so each such combination has exactly one ATA address.

Every memecoin you bought or were sent needed such an account. When you sell everything the balance drops to zero, but the account itself stays on chain. After a few months of trading memecoins a wallet can collect dozens of empty accounts, including ones from airdrops and spam tokens you never wanted.

How much SOL one account locks[1][2]

The Solana docs say every account must hold a refundable minimum lamport balance, proportional to its data size, to remain on chain. This used to be called rent. The documented formula is (account size + 128) × 3,480 lamports per byte-year × 2 years.

A regular token account in the Token program is 165 bytes. The formula gives (165 + 128) × 3,480 × 2 = 2,039,280 lamports, about 0.00204 SOL. A Token-2022 ATA with the automatic ImmutableOwner extension is 170 bytes, or 2,074,080 lamports. A Token-2022 mint can require further account extensions, which make the account larger and the deposit higher.

Whoever creates the account pays the deposit. According to the docs the payer can be someone other than the ATA's owner, for example an airdrop sender. The refund on closing does not automatically go back to whoever paid, though, but to the address named in the close instruction.

When an account can be closed and where the SOL goes[3]

Closing an account deletes it and moves all of its lamports, deposit included, to a destination account. The account owner or its close authority signs the instruction and chooses the destination.

There is one condition: the token balance must be zero. The exception is wrapped SOL, an account of the native SOL mint, which the docs say can be closed with a balance to reclaim the SOL. A frozen account with a zero balance can be closed too. The Token-2022 program runs extra checks for some extensions, so closing such an account can fail even with a zero balance.

  • The account's token balance is zero, unless it is wrapped SOL
  • The refund destination is your own wallet
  • You know whether the account belongs to the Token or Token-2022 program
  • You are not closing the account for a token that is about to arrive, for example from vesting

Leftover tokens: burn instead of selling for dust[4]

Often an unsellable remainder is left behind, or a token someone sent you unasked. According to the docs a burn permanently decreases the account balance and reduces the mint's supply by the same amount. The account owner or an approved delegate signs it. Once burned to zero, the account can be closed.

The native SOL mint cannot be burned. For wrapped SOL the docs point to closing the account. Do not try to sell an unknown spam token: interacting with its pool or with a site named in the token is a typical start of a drainer scam, which our airdrop guide covers.

Delegates and permanent delegates: who else can move your tokens[5][6][7]

A token account can have a delegate, an address that may transfer or burn tokens up to a set allowance. The account stores one delegate and one amount at a time, and a new approval overwrites the previous one. Revoke clears the delegate and resets the allowance to zero. In the Token program the account owner signs it, and in Token-2022 the delegate itself can also revoke.

A Token-2022 permanent delegate works differently. It is a mint-level authority that can authorize transfers and burns from any token account of that mint, and the account owner cannot revoke it. Closing an empty account changes nothing here, because the problem is the token, not the account. The risk report on a token page shows Token-2022 extensions in their own row.

The traps of “reclaim your SOL” sites[3][5][8]

Closing an account is an ordinary transaction, so any site that builds it asks for your signature. The signature means what it means on a swap: consent to everything in the transaction. A malicious site can add a token transfer, an approve for a stranger's delegate, or name its own address as the refund recipient.

Before signing, read the simulation in your wallet. A safe transaction contains only close instructions and perhaps burns, and your SOL balance goes up. If the wallet shows tokens leaving that you did not mean to burn, a new delegate or a refund to another address, reject it. A site may also take a cut of the reclaimed amount, so check how much SOL actually comes back.

Every transaction pays the network's base fee: 5,000 lamports per signature. With several closes in one transaction that fee is negligible next to the deposits, but with one account per transaction it eats into the refund.

A worked example on a hypothetical wallet

The numbers below are hypothetical. They show the arithmetic, not the state of any real wallet.

Hypothetical numbers, not market data

A wallet has 40 empty Token program accounts and 10 empty 170-byte Token-2022 ATAs. The deposits are 40 × 2,039,280 + 10 × 2,074,080 = 102,312,000 lamports, about 0.1023 SOL. You close them in five transactions with one signature each: 5 × 5,000 = 25,000 lamports in base fees. About 0.1023 SOL minus 0.000025 SOL, and any priority fee, comes back to the wallet.

Check what stuck

A pass is 3 of 4 right answers.

Question 1 of 4

When can a regular token account on Solana be closed?

Sources

Primary material used to verify the information. A number beside a section points to the related source. A link is not an endorsement of the asset discussed.

  1. 01Solana: Accounts (minimalne saldo przechowywania) [Solana: Accounts (minimum storage balance)]
  2. 02Solana: Create a token account
  3. 03Solana: Close token account
  4. 04Solana: Burn tokens
  5. 05Solana: Approve delegate
  6. 06Solana: Revoke delegate
  7. 07Solana: Permanent delegate
  8. 08Solana: Fees

Spotted an error or something out of date? Write to kontakt@memecoiny.pl. How corrections work

Empty token accounts on Solana: where they come from, how much SOL they lock and how to close them safely | MEMECOINY