Hey guys, I’m trying to bring my wallet from Electrum over to Bitcoin Core.
I’ve already exported the private key from Electrum. But whenever I use the command importprivkey 'privatekeyfromelextrum', I keep getting an error saying that only legacy wallets can use this command...
Any tips or help would be appreciated!
Moving wallet from Electrum to Core
4 replies 316 views
gr3g.0rbitHero Member
Posts: 1025 · Reputation: 2646
#2Aug 27, 2023, 08:41 AM
Use importdescriptors command followed by the descriptor containing your WIF private key with checksum and timestamp.
For example (native SegWit):
To get the correct checksum, use the command, getdescriptorinfo.
For example:
If your address is legacy from old version of Electrum, replace "wpkh" with "pkh".
The importprivkey command will work if you create a non-descriptor wallet but Bitcoin Core will soon drop support for such wallet format
so it's better to learn those descriptor wallet-comaptible commands.
king_tokenFull Member
Posts: 26 · Reputation: 293
#3Aug 27, 2023, 11:29 AM
nc50lc has already provided a great answer to your question. I just wanted to add that the official Bitcoin Core documentation offers comprehensive insights into commands, usage, and wallet management. You can access it here: https://bitcoincore.org/en/doc/
The private key appears to be a p2pkh. Does that change anything?
This wallet was originally a Zelcore wallet that exports the private keys is WIF format.
Thank you!
jake.chainSenior Member
Posts: 280 · Reputation: 1307
#5Aug 27, 2023, 09:08 PM
Private keys don't specify a script type, but if you want to recover a P2PKH address beginning with "1", then just change from wpkh to pkh in nc50lc's instructions above.
Run getdescriptorinfo to get the checksum, then importdescriptors with the calculated checksum.
Related topics
- Moving to a Wallet Secured with a Passphrase 5
- Issue with Bitcoin Core Wallet after power outage 8
- Using Electrum to Transfer from BRD Wallet with HPS Address 8
- Transforming my wallet into an HD wallet bitcoin core 26 4
- Recovering a Bitcoin wallet and address 8
- CipherSeed: A Comprehensive Guide to Super-Secure Crypto Wallet Backups 5