How to Reclaim Excess SOL After Rent Reduction
Solana has reduced rent requirements, leaving excess lamports in token accounts and program-owned accounts that can now be reclaimed using new instructions.
Video
Video available
Solana’s Token Program now includes the WithdrawExcessLamports instruction, which allows users to recover SOL held above the rent-exempt minimum in token accounts, mints, or multisig accounts without altering token balances or closing the account. The instruction moves surplus lamports to a destination while keeping the account operational, simplifying the process of reclaiming excess funds after rent reductions.
This feature is accessible via the @solana-program/token-2022 package for the Token 2022 program.
For program-owned accounts, such as DeFi position PDAs or escrow vaults, developers must implement reclaim logic within their own programs, following a realloc pattern similar to resizing an account. The process involves shrinking the account to its required data size and then transferring lamports above the new rent-exempt minimum to a destination account.
This ensures only surplus SOL is moved while maintaining account functionality.