12

I am switching from bitcoin-qt to Electrum, and it seems as if I will need to download the blockchain again. Can I copy and paste my wallet.dat into Electrum's files?

6

According to this FAQ:

In Electrum 2.0, you cannot import private keys in a wallet that has a seed. You should sweep them instead.

If you want to import private keys and not sweep them you need to create a special wallet that does not have a seed. For this, create a new wallet, select “restore”, and instead of typing your seed, type a list of private keys, or a list of addresses if you want to create a watching-only wallet.

You can get the private keys from Bitcoin Core using dumpprivkey as described in Using dumpprivkey to make a paper backup.

| improve this answer | |
4

If you export the private keys for the addresses you want to keep then you are literally your own bank, most wallets allow you to import private keys in some way. I don't know the specifics of doing it on Electrum though.

To export from bitcoin-qt go into the debug console from the menus, and enter

dumpprivkey "1bitcoinaddresshere"

Keep that key safe - it is the key to all coins in that address now, past & future. Don't leave it on your desktop or dropbox, preferably carefully copy and paste it into the other wallet without writing to disk.

| improve this answer | |
2

I have to disagree with the other 2 answers at the time of this writing. While indeed wallet.dat contains all the critical information, and in theory you could just use it with another application, in practice the wallet file format is not consistent between applications, and AFAIK you cannot use that file elsewhere.

Your best course of action depends on your needs, but it's probably to export your private keys, import them elsewhere (such as blockchain.info), and send the coins to the wallet you want to use going forward.

| improve this answer | |
  • What do you mean "import them elsewhere (such as blockchain.info)"? – Geremia Feb 14 '15 at 21:57
  • 1
    @Geremia: After you've exported your private key, you can import it to another wallet. Once the key is imported, you can spend the coins it controls using this wallet. Every wallet has its own interface for importing. An example for a wallet to which you can import the key is blockchain.info. – Meni Rosenfeld Feb 15 '15 at 12:08
2

This question is already answered in the Electrum tutorials http://electrum.org/tutorials.html#switching-to-electrum

What to do with my old addresses and wallet when switching to Electrum?

The best way to switch to Electrum is to send all the bitcoins you have on your old wallet to one of the addresses on your Electrum wallet. This way you'll have all your bitcoins secured with your seed.

You could import the private keys from your old client, but you will have to keep a backup of those keys separately as they won't become part of your Electrum seed.

Remember not to totally delete your wallet.dat if you gave your addresses for the deposite to other people

| improve this answer | |
2
  1. Start Bitcoin Core with the wallet.dat you want to export
  2. Dump your private keys via Bitcoin Core's Console using dumpwallet
  3. You'll get a list of private key to address pairs in the following format:
L4ysibEFMBQc3hfr7tvUyV4nBP1YQ3AgDewszoYq5czMtXotmmro 2020-08-21T14:36:58Z change=1 #addr=bc1qpw40dkvcj23zt3efvdwqr7ddfunwktx11f3tjf
  1. Extract all private keys (they are in the first column, e.g. L4ysi..mmro)
  2. Create a new Electrum wallet, select "Import Bitcoin addresses or private keys", convert your keys according to the rules available by clicking on "Info" button (you may not need to convert if your wallet.dat is quite old) and you're good to go!

The above is tested on Bitcoin Core 0.20.1 and Electrum 4.0.2.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.