23

Question says it. I spent 20 mins Googling. Saw several links on bitcointalk.com but amazingly found no solution to this. Am I the first one trying to do this? Note the following are not the solutions I am looking for:

  1. Transfer the BTC from Bitcoin-qt to Multibit by making a transaction
  2. Some commandline geeky stuff
4
  • 2
    > Some commandline geeky stuff Well, that's the way it is done. You could pay someone to do that process for you -- but then you would need to trust them as they have your private keys. Nov 11, 2012 at 21:54
  • That "commandline geeky stuff" can be done through the debug window / console that is available with the Bitcoin.org client v0.7. Nov 11, 2012 at 21:56
  • The method of importing the wallet via Blockchain.info no longer seems to work. I can produce a JSON file from dumpwallet.py but Blockchain.info apparently fails to recognize it for some reason.
    – user2637
    Jan 16, 2013 at 12:56
  • Unfortunately there are some commandline geeky stuff commands that you will need to execute. Please see my answer below.
    – Scott
    Sep 14, 2013 at 14:18

4 Answers 4

20

Manual Steps

  1. Copy your public receiving addresses from Bitcoin-Qt.
  2. Go to the Bitcoin-Qt console: click Help/Debug Window and then select the Console tab.
  3. Run walletpassphrase [your password] [timeout in seconds] to unlock your password protected wallet.
  4. Run dumpprivkey [Receiving Bitcoin Address] for each receiving address to be migrated to MultiBit. There may be hidden private change addresses in Bitcoin-Qt which don't show up in the receive tab. Run listaddressgroupings.
  5. Copy the results of dumprivkey for each address (which are the corresponding private keys).
  6. Start the Multibit client and create a new wallet.
  7. Click Tools/Export Private Key after selecting the Do not password protect export file option.
  8. Open the exported file in a text editor.
  9. Below the private key generated by MultiBit, paste the private keys you have copied above. Remember to paste them before the End of private keys line.
  10. After each private key, add a date that is prior to when you created the corresponding wallet. (You can check this date in the Bitcoin-Qt Transactions tab and scrolling to the very bottom.)
  11. Repeat for all addresses you want to move to Multibit Client.
  12. Save the key file and import it to the Multibit client using Tools > Import Private Keys.
  13. In MultiBit, you may not see your total until you click Tools > Reset Blockchain and Transactions
  14. In order to protect yourself from theft, delete the private key files.
  15. Done!
9
  • 2
    Scott's answer above is excellent, but I think there are some final steps missing, which are: After step 8: 9. Save the file that you added the keys to 10. Click Tools/Import Private Key. Find the file you saved and import it.
    – Velonius
    Sep 14, 2013 at 20:29
  • 2
    By the way, this is a great answer, but besides the comment of @Velonius above, you have to make sure to put a date prior to the creation of your wallet when pasting the private key into multibit.key file. This ensures the proper replaying of the blockchain which will then pick up all the transactions.
    – adavid
    Sep 22, 2013 at 19:45
  • 1
    Also missing, if you have a password on your wallet, is before step 3 writing: walletpassphrase [your password] [timeout in seconds] Jan 27, 2014 at 18:47
  • 1
    My transactions were picked up, but my total did not appear in MultiBit until I did "tools > reset blockchain and transactions" at the end (after step 11). Also, be aware that the QT-client uses hidden private change addresses that don't show up in the receive tab. listadressgroupings in the Qt-debug-console showed my missing addresses which I then followed steps 3-10 for to make ALL of my transactions and money appear in multibit. Get all addresses from bitcoind Mar 15, 2014 at 12:24
  • 1
    Simpler now: bitcoind -daemon; bitcoin-cli dumpwallet wallet-dump.deleteme; grep label= wallet-dump.deleteme | cut -d' ' -f1,2,3 > import-into-multibit.key -- but don't do it on insecure storage! Those contain raw private keys. I'd like to improve this by importing labels as well, but couldn't figure it out. Oct 29, 2014 at 0:33
8

Here is one way to do it without the "command line geeky stuff".

  • Visit https://blockchain.info/wallet/import-wallet. Drag the Bitcoin-Qt wallet.dat file into the dotted area. Follow the instructions.
  • Login to the new wallet. Under the Backup heading click download.
  • Open multibit choose Tools -> Import Private Keys. Now import the wallet.aes.json file just downloaded.
  • Delete the keys from the blockchain.info wallet.

However since the goal isn't to setup a blockchain.info wallet you would be much better off using pywallet https://github.com/jackjack-jj/pywallet to dump the wallet and the keys directly.

5
  • 4
    This is a good solution but yes, the goal was do the export without giving my private keys to a 3rd party. I think what I will eventually end up doing is a transfer via a transaction (easiest but not the cheapest way, since the transaction size will be large).
    – Jus12
    Nov 12, 2012 at 9:43
  • The way blockchain.info works it stores your wallet but still encrypted with your password, they don't not keep access your wallet.
    – Gopoi
    Jan 17, 2013 at 22:42
  • blockchain.info has some issues with importing. Few keys were not imported. I guess if the number of keys are large, the problem occurs.
    – Jus12
    Sep 9, 2013 at 20:19
  • 7
    This is not a good solution. I do not want a third party to learn all my secrets...
    – adavid
    Sep 22, 2013 at 19:58
  • 4
    I also would strongly advise against this. Check out Scotts answer. Did work for me.
    – stigi
    Nov 18, 2013 at 17:35
3

It does not answer your question of getting your private keys out of bitcoin-qt, but this link explains how you import a single private key into MultiBit:

http://multibit.org/help_importASingleKey.html

If you have more than one private key it is simply more rows in the import file.

The date alongside each key is a bit non-obvious. It has to be before the date of the first transaction using that key so that the blocks with the transactions in can be found. I recommend just finding the first transaction in your wallet and putting the date one day before it in on every row. (Using a day earlier avoids any time zone problems).

Note that the import only knows about the sipa format private keys (the ones beginning with a 5). It does not understand compressed keys. ( What is a compressed Bitcoin key? )

2
  • Still strange to see people name the base58 private key format after me. I'd prefer them adding support for compressed public keys (which I also came up with, including the base58 format...). Nov 11, 2012 at 19:33
  • Hi Pieter, yes I will no doubt get round to adding parsing of compressed keys - it is in my issues list. As the export files are mainly to backup the MultiBit keys it is not top of the list though. I think you will probably have to get used to being famous. :-)
    – jim618
    Nov 11, 2012 at 19:44
0

I wrote this a while ago and used it to convert all my wallet.dat s to multibit.key to be able to import them to multibit.

https://github.com/shayanb/Open-Wallet-Format

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