Deleting Accounts
The owner of an account can send an AccountDelete transaction to deletes the account and related entries from the ledger, sending most of the account's remaining XRP balance to another account. To discourage wasteful creation and deletion of accounts, deleting an account requires burning a higher than usual amount of XRP as the transaction cost.
Some types of associated ledger entries block an account from being deleted. For example, the issuer of a fungible token can't be deleted while anyone holds a nonzero balance of that token.
After an account has been deleted, it can be re-created in the ledger through the normal method of creating accounts. An account that has been deleted and re-created is no different than an account that has been created for the first time.
Requirements
To be deleted, an account must meet the following requirements:
- The account's
Sequence
number plus 256 must be less than the current Ledger Index. - The account must not have any "deletion blockers" in its owner directory. This includes cases where the account is a sender or receiver of funds. See below for a full list of deletion blockers.
- The account must own fewer than 1000 objects in the ledger.
- The transaction must pay a special transaction cost equal to at least the owner reserve for one item (currently 0.2 XRP).
Deletion Blockers
The following ledger entry types are deletion blockers:
Escrow
PayChannel
RippleState
(trust line)Check
PermissionedDomain
(Requires the PermissionedDomains amendment )
Any other types of ledger entries that an account owns are automatically deleted along with the account.
Cost of Deleting
fail_hard
option when submitting an AccountDelete transaction.Unlike Bitcoin and many other cryptocurrencies, each new version of the XRP Ledger's public ledger chain contains the full state of the ledger, which increases in size with each new account. For that reason, you should not create new XRP Ledger accounts unless necessary. You can recover some of an account's 1 XRP reserve by deleting the account, but you must still destroy at least 0.2 XRP to do so.
Institutions who send and receive value on behalf of many users can use Source Tags and Destination Tags to distinguish payments from and to their customers while only using one (or a handful) of accounts in the XRP Ledger.