In this short tutorial, I will explain how to export your private keys out of your Electrum wallet.
Open your Electrum wallet. In Electrum’s menu, click on Wallet, on Private keys and on Export.
All the relevant information will appear in a new window. Your BTC addresses will be on the left alongside their private keys on the right. They are likely to start with something like p2pkh:, p2wpkh-p2sh: or p2wpkh:. This prefix is not strictly part of the private key. Rather, it specifies what kind of address shall be generated.
- p2pkh: will generate an address that starts with 1 (i.e., a legacy address)
- p2wpkh-p2sh: will generate an address that starts with 3 (i.e., a segwit address)
- p2wpkh: will generate an address that starts with bc1q (i.e., a native segwit address)
You can copy-paste the private keys directly from the window or you can export them in CSV or JSON format.
If you import the private keys into another software, you may have to leave out the prefix and specify somehow else what kind of address shall be generated.