Skip to content

Instantly share code, notes, and snippets.

@paulofreitas
Last active October 14, 2025 21:23
Show Gist options
  • Save paulofreitas/cbc667a5ba656872789111c3553d8825 to your computer and use it in GitHub Desktop.
Save paulofreitas/cbc667a5ba656872789111c3553d8825 to your computer and use it in GitHub Desktop.
Consolidating XLM wallets

Consolidating XLM wallets

Ever wanted to get rid of extra XLM wallets without losing your reserved balance? You can do it.

First, remove all offers and trustlines from the account using StellarTerm. You'll need your secret key to log in there. Each trustline and exchange offer locks 0.5 XLM in addition to the default 1 to 1.5 XLM reserved minimum balance.

Once you've moved all assets and removed every offer and trustline, you're ready to use LOBSTR Merge Tool. There you'll enter the recipient address and MEMO (if required). In the next step, you'll provide your public key (sender address) and secret key to merge the balance into the recipient account. The merge costs 10% of your reserved balance (typically around 1 to 1.5 XLM).

Don't have a secret key?

No problem! As long as you have a recovery/mnemonic phrase, you can derive your secret key using stellar-hd-wallet tool from Stellar.

Using the tool is simple:

git clone https://github.com/stellar/go
cd go/tools/stellar-hd-wallet
# OPTIONAL: if you don't have Homebrew installed and need to install go
# /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# OPTIONAL: if you don't have Go installed
# brew install go
go run main.go accounts

You'll be asked how many words are in your mnemonic phrase, then prompted to enter them one by one. The tool will display your Mnemonic phrase, BIP39 Seed, derived m/44'/148' key and the addresses from this key. At the first address (m/44'/148'/0') you'll find both your public key (wallet address) and secret key.

That's it! You can now use this secret key to log in to StellarTerm or to merge accounts with the LOBSTR Merge Tool.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment