Sweeping your private keys into Electrum

Sweeping your private keys means to send all the bitcoins that can be unlocked by those private keys to an address in your existing deterministic Electrum wallet. It is a one-time on-chain operation that will cost you transaction fees.

To sweep your private keys you go to Wallet menu > Private keys > Sweep:

Then you enter your private keys one per line:

The address displayed in the window above by default will be an address in your wallet. This is where all the funds will be sent.

Your private keys need to be in Wallet Import Format (WIF) or mini private key format. These are standard formats for private keys. More about that here.

Note: if the addresses in the originating wallet of the private keys begin with 3 you have to prepend “p2wpkh-p2sh:” to each private key before sweeping it. If the addresses begin with bc1 then you prepend “p2wpkh:”. Click on the info button to see examples.

Click on sweep and electrum will look up what bitcoins have been sent to the corresponding address. It’ll then display a window where you set the fee and enter the wallet password if any. After you’ve set a suitable fee click on send and the coins will be swept to the address you set in the previous step.

86 thoughts on “Sweeping your private keys into Electrum”

  1. What does it mean when it says the sweep is “unconfirmed”? Does this mean I have to wait a bit for it to go through? My coin appears in my new Electrum wallet but it’s also still showing up in the old multibit wallet too.

    1. It means your transaction hasn’t been incorporated in the blockchain yet. That happens within 10 minutes to an hour so it should have happened by now.

    2. It says mini private key format is supported, I’d like to sweep 30-character S-starting one but it’s not recognised. Do I need to convert it into some other format, if so, how? Thank you.

  2. Hi I am trying to extract BCH and BTG from a QT wallet on OSX
    My plan is to use Coinomi to sweep the QT private key using their Chrome extension after having imported my BTC to Electrum

    So far:
    * Downloaded verified and installed Electrum 3.0.3
    Now what? Do I sweep the private key from QT to Electrum and if I do is that like sending myself BTC? It seems to cost 19mBTC or almost 350USD??? That cannot be right. It cost 15 USD or so to send one to a normal online broker…

    1. Yes you sweep your keys. If the transaction size is large then there will be high fees. Generally speaking fees are very high these days. More about how fees are calculated here: https://bitcoinelectrum.com/how-to-manually-set-transaction-fees/

      You can always low ball the fee and bump it later if the transaction doesn’t confirm in a timely manner. More info bumping the fee here: https://bitcoinelectrum.com/frequently-asked-questions/#my-bitcoin-transaction-is-not-confirming-what-can-i-do

  3. Hi, i’m trying to sweep a Pandacoin paper wallet I was given into Electrum, but the sweep button is greyed out.

    Can i use Electrum for Pandacoins? if not, is there another wallet you would recommend for this?

  4. Hi!

    Thank you for these very good info pages! Keep up the good work!

    I have some BTC in “behind physical coin” (bought from Denarium) so I have a my private key on physical hologram paper. My idea is to get those BTCs to my Electrum Wallet.

    Problem is that when I try to “File -> New/restore -> wallet name and OK -> standard wallet and Next -> Use public or private keys and OK -> .. The “Next”-button does not activate even if I put the correct private key. It is 30 digit long, and I do not know what “xprv/yprv/zprv” means – I have just put the 30 digit private key there. So that is my showstopper šŸ™‚ Any help?

    OR instead of above – can I just use this “Sweeping” -option? I’ll get my BTCs to Electrum via that way also?

    Thank you very much for help!

    1. You are making a mistake in one of the steps when importing your private key. They moved around some of the UI elements in 3.0. See the article about it here: https://bitcoinelectrum.com/importing-your-private-keys-into-electrum/

      Regarding sweeping that’s an option too. Sweeping means the coins are sent to an address in your electrum wallet. It is an on-chain operation that has transaction fees associated with it. The advantage of sweeping over importing is that the private keys that control the coins changes to the ones behind the destination address you specify in the sweep window which, by default, is an address in your electrum wallet. This makes backups easier since you can easily back up an electrum wallet by just writing down its seed words. It is actually possible to sweep to any address so if you intend to send the coins to an exchange you can use the sweep option to send to the exchange’s address in one fell sweep šŸ™‚

  5. I made a huge f*!k up. The BTC address wasnt visible anymore after a JAXX update. The 12 word phrase didn’t work either. So I tried to upload the funds with my address and privatekey at Electrum. I used the function sweep privatekey and filled in the required fields (I thought) and pushed BROADCAST. DAMN IT what an high fee! And now the most stupid action. I filled the same address as where I was sending from. So $450 gone with a useless action (0.55 -0.045 fee!!) I was sick of it! Its in my wallet now.. I am just a moron lol. first mistake and the last one i hope.

  6. I have a realy weird Private Key Encrypted and i don`t know how to use.
    It looks like this:FsdvSCsdcvjkNMFUE76DSFhfhu87STYD6T7fbfuHUY7hjnf++FFJKdFKjvckJKFjkdFDhjfsdhFfdsF97S7D9FSDfFvcFdfX/YvffGBDvfl= (this is not the real key).
    Can someone help me.

    Jord

    1. that looks like something that is base64 encoded. where did you get it? I suggest you seek help on one of the community forums: electrum.org/#community.

    1. create a new wallet https://bitcoinelectrum.com/creating-an-electrum-wallet/ and then sweep https://bitcoinelectrum.com/sweeping-your-private-keys-into-electrum/

  7. in attempting to sweep a priv. key into an existing wallet I get the following error: invalid prefix (0) for WIT key (1). The key starts with a 1 and if I use it to make a watching wallet I see an amount. This used to work. Any ideas? I tried various prefixes but I think they are for older keys–they don’t help.

    1. What you have there is an address not a private key. A private key looks like the following:

      https://en.bitcoin.it/wiki/Private_key#Base58_Wallet_Import_format

  8. I have problem with LTC on print from bitcoin ATM. I try to sweep the to my electrum ltc wallet, but I keep getting error: no inputs found. (Note that inputs need to be confirmed). Already contacted with atm company and they said they can see funds and everything is good from their side. I can also see funds on this address in LTC block. What’s the problem?

    1. note i only know about bitcoin electrum so this may be way off but i would suggest you click on ‘info’ on the sweep window. most likely you need to prepend the script type to the private key. if this doesn’t do it ask in reddit.com/r/litecoin.

  9. I am trying to transfer my bitcoins from wallet 1 to wallet 2 by using sweep (lost seed, cannot transfer to other wallet due to missing 2fa code generator). From wallet 1, the private key is generated from an address (starts with 3) with bitcoins. Electrum gives private key in format p2sh:PRIVATE KEY

    In wallet 2, after clicking to wallet –> Private keys –> Sweep, private key from wallet 1 is pasted in following format: p2wpkh-p2sh:PRIVATE KEY

    Then I get the “No inputs found.” error. Same error I get when pasting only private key, without the script type. No idea what is wrong – please help!

    I am using Electrum 4.0.9. on a Mac Catalina, new wallet is using legacy 2fa

    edit: when trying to do the sweep with key in format p2sh:PRIVATE KEY, I get I error: Exception(‘unexpected txin_type sweep: p2sh’)

    1. no you have to do a restore from seed and choose to disable 2fa when asked. see this guide

      https://bitcoinelectrum.com/restoring-your-standard-wallet-from-seed/

    2. Mark – Did you have any luck doing this? I am in a similar situation at the moment (Have Private Keys, PW, and Access to Wallet, but don’t have seed or the original 2FA Device)…

      Looking for ways to resolve this

      1. you have only one private key when you need 2 out of 3 behind each address. i suggest you contact trusted coin for help with resetting your 2fa.

  10. Is there anyway to sweep an old wallet and avoid dust? I only want my original coins and not what others sent.

    1. you can do an imported private key wallet and then use coin control to only spend specific outputs:

      https://bitcoinelectrum.com/importing-your-private-keys-into-electrum/

      https://bitcoinelectrum.com/how-to-spend-specific-utxos-in-electrum/

  11. Hmmm,

    “Note: if the addresses in the originating wallet of the private keys begin with 3 you have to prepend ā€œp2wpkh-p2sh:ā€ to each private key before sweeping it. If the addresses begin with bc1 then you prepend ā€œp2wpkh:ā€. Click on the info button to see examples.”

    Is this still necessary? And if so where is the info button to see examples?

  12. I am having similar problem as Mark. Trying to sweep old private key in Electrum and get message “No input found”. My prive key starts with L35. Do I need to prepend it with something?

  13. I ve tried to sweep a private key – and already destroyed the paper (don’t ask :-()

    Now I m getting the Error

    “mempool min fee not met”

    Is there a possibility to change the fee?

    1. do it again this time paying attention to what you see on your screen. a window with the option to set a fee appears right after you click on sweep in the sweep window. you can choose eta or mempool from the list next to the fee slider and this will set a market appropriate fee for you.

  14. Hey, im trying to claim my bitcoincash from an old electrum wallet btc multisig wallet. I exported my private Keys and i try to do it by sweeping on electron. So what i understand is, that i have to copypaste my private key from the old btc adress (where the bitcoincash coins are still) into the sweep window. The problem is:
    i cannot click the “sweep” button. i tryed it with the public key, with a 12 words seed, with the phrase “2p2wpkh-p2sh:” before my private key, but its still unclickable. What i am doing wrong ? My old btc adress starts with a “3”.

    1. a multisig wallet is not a p2wpkh-p2sh wallet. it’s a p2sh wallet and your best bet is to simply open the electrum wallet file using electron cash. in electrum you can backup the wallet file to your desktop via file > save backup and in electron cash open it via file > open.

  15. Hi! I have a paperwallet with a legacy address (starts with 1), made using bitcoinpaperwallet (bitaddress). At that time I also encripted the wallet with a passphrase (in theory, if you want to spend, you must have that passphrase). Now I have a Trezor One, so I want to sweep the coins from that address to a new one in the hardware wallet.
    To do that I tried to use Electrum: Standard wallet > Hardware device > PIN + Passphrase > native segwit, Encrypt wallet file.
    Wallet > Private Keys > Sweep: Write my private key (start with 6) in one line and press enter. Sweep button still grey. Append “p2pkh:” and still grey. I am sure the private key is written correctly. Any help? Or may be there is another secure way to do so… suggestions are very welcome. Thank you!

    1. you have to decrypt the private key using the wallet details tab of bitaddress.org. this will give you two private keys compressed and uncompressed with two different addresses. import/sweep the private key corresponding to the address which has unspent coins.

      also i sure hope you meant bitaddress.org and not bitcoinpaperwallet dot com. the latter turned out to be a scam operation.

  16. Hey guys,
    I could use some help. I’ve stumbled upon (on an old computer) an written document with my private keys and addresses for a Electrum wallet I used back in 2018. I did lose the seed, though…

    I’ve tried accessing my account through various ways (results in bold)

    Import private keys –> Electrum crashes
    creating a new wallet, aborting as soon as I have my new seed and change the keystore type (to BIP32), derivatino path (m/49’/0’/0′) and script type (to p2wpkh-p2sh) –> unable to sweep private keys (see 3 and 4)
    sweeping private keys with prepend ‘p2wpkh-p2sh:’ –> Sweep-button disabled
    sweeping private keys without prepend –> Error: ‘Exception(‘unexpected txin_type to sweep: p2sh’)’
    What I am able to do is to create an read-only wallet with my address and view my balance (which is still there, fortunately).

    I really don’t know what else to do, so if there’s anyone out there who is willing and able to help out, I’d truly appreciate it.
    Thanks!

    1. i suggest making a thread on bitcoin talk or /r/electrum subreddit and posting the link here. this way we can have a proper back and forth.

  17. Hi there, am trying to sweep my bitcoin on electrum and “sweep” botton remain blank, kindly advice what i use do..

    1. it could be that you pasted in something other than a private key or the private key’s checksum does not validate

      private key must be in one of the supported formats. either WIF or mini private key format. you can see what WIF looks like here: https://en.bitcoin.it/wiki/Private_key#Base58_Wallet_Import_format

      if the private key is in the correct format then make sure you didn’t miss any characters in it. Copy paste it again and leave no trailing or leading spaces or new lines.

  18. Bonjour,
    Je cherche a rƩcupƩrer mes fonds sur Bitcoin Core,
    On m’a aidĆ© a recupĆ©rer les cles privĆ©s format WIF a les isolĆ©s,
    seules, ligne par lignes.
    Je pense donc y avoir des fonds dessus mais
    ni BItcoin core et plus rƩcement Electrum
    Ne me permettent de recupƩrer ces fonds.
    Pouvez-vous m’aidĆ© ?SVP?

  19. I’m a little lost trying to recover my bitcoin cash into and electron wallet using the private keys from an electrum wallet which is now empty. I had 1.877 bitcoins at the time of the fork bu have since sold them

    I have an electron cash wallet which and having imported the addresses my coins are visible but read only.

    I have exported the private keys as a CSV file from electrum. that file lists 38 address and private keys.

    I cant tell which private key relates to the balance at the time of the fork so do I copy and paste all 38 private key in the sweep or is there a way to identify which private key relates to the balance?

    as I say a bit confused as all I want to do is make the wallet accessible and then sell the coins as I need the cash

    thanks for any advise/clarity on this

    1. since you are moving from electrum you should simply restore from seed using electron cash instead of dealing with individual private keys. in electrum you can get the seed from wallet > seed if you haven’t written it down already.

    2. found the right Private key for the balance but after I sweep it I still get a watch only wallet notice…

      made an image file here
      https://phasm.co.uk/bitcoin-cash01/

  20. Iā€™m trying to sign my 2/3 multi sign transaction on climb.in but everytime I enter my private key for the refund address I used, the website tells me the input is incorrectā€¦
    Any advice would be really appreciated

    1. remove the prefix that electrum adds to the private key i.e. the colon and everything that comes before it. your private key should begin with L, K or 5.

  21. Hi there,
    I have an old paper wallet with only the private and public keys written down (no QR code). My private key begins with 5 (so uncompressed). I am unable to get Electrum to recognize it. What am I missing/how can I resolve this? Thanks for your help.

  22. Good day
    I keep on getting an ā€œNo inputs found.ā€ error when I try to sweep my Privacy Key in electrum. My privacy keys start with a “L” or “K” and my addresses all start wit a “1”. Not BC1 like some addresses mentioned. Please advice what route I should try to resolve this issue. I did try to prepend like the samples under info Tab but same error.

    1. The key includes a checksum so make sure you are entering it correctly. If it is entered incorrectly the checksum will not validate and electrum won’t let you sweep it.

    2. Make sure you are entering the key exactly. Capitalization and order of the letters matters. There’s a checksum in there to detect typos and that’s likely what’s tripping you up.

  23. “Sweeping your private keys means to send all the bitcoins that can be unlocked by those private keys to an address in your existing deterministic Electrum wallet. It is a one-time on-chain operation that will cost you transaction fees.”

    Ok. So, I have 1 private key on a paper wallet with 0.1 BTC in it’s corresponding bc1q-address and I also have a newly generated Electrum wallet which is of course emtpy (0.00 BTC). I’m going to sweep the private key with Electrum, and as far as I understand the fee will be deducted from that 0.01 BTC and I’ll end up with something like 0.09999937 BTC in one of the adresses of that newly generated Electrum wallet. Is this correct (0.01 minus the fee, right)? The initial private key/address holding the initial 0.01 should be now totally empty?

  24. I’m a novice when it comes to bitcoin, and I want to purchase the Private key from the site. I have tried reading all about how to “sweep” or import” but I’m not making any sense of it.

    I downloaded Electrum from play store and I can’t seem to find the sweep option anywhere.
    (Maybe it’s cos I’m using a mobile device)

    But I will really need some help with the private key thingy if anyone is willing to put me through šŸ˜‰

    1. Private keys are not supposed to be shared and anyone selling private keys is looking to scam you.

  25. I thinks I made a big goof. I paid a transaction that went into a 2/3 multisig wallet. When I made the payment, i also needed to convert so I used an exchange and made the payment through the exchange. I didnt think it through because the vendor no longer had the item, was gone, whatever, anyway, the payment was returned to me. I have the signed transaction that I must sign to get my funds back. Is there any way to do this, I apparently dont have the correct private seed to sign the transaction because the exchange has it? Or should I be able to do this somehow? If anyone can help message me I would pay a % for the help…

  26. In 2018 I had BTCP after the fork and I now still have my seed and list of public and private keys. Iā€™ve been unsuccessful in uploading or sweeping or importing these keys to the new 4.2.0 electrum walletā€¦ if I have the seed and the public and private key (26 pairs/addresses) what do I do to see how much BTCP there is?

  27. I am new to Electrum, just sweeped BTC from a private key. My question is, i read about signed and unsigned transactions and broadcasting? I have no clue what that is for, so far it shows my BTC incoming amount but it is unconfirmed. Do I need to do anything else at all to receive it? More or less how long does this take.

  28. Hi. I have a casascius bitcoin. I have peeled the hologram and the key on the outside started **1 and the key under the hologram started with 5. Please could someone tell me how I sweep this into electrum.

    1. follow the guide above and use the key under the hologram. It should start with S and not 5:

      https://en.bitcoin.it/wiki/Mini_private_key_format

  29. Hello, I have a software wallet that shows a certain amount of btc when I look it up on bitcoin explorer but it doesnā€™t show in the wallet on platform (altercointrader) I donā€™t have a private key for this wallet, i have never got one when I opened it.how do I get it?

    1. if it’s a custodial wallet then looking up the address on a block explorer will be misleading. altercointrader has the private key for the address and only they control the funds. you can ask them for the private key but they will be unwilling to share it with you. besides private keys aren’t meant to be shared.

      to securely withdraw funds to a wallet that you control you have to first create a new wallet in electrum and then share an address from the receive tab with altercointrader. tell them to send your bitcoins to that address. don’t share any private keys or the seed words with anyone.

      creating a wallet in electrum: https://bitcoinelectrum.com/creating-an-electrum-wallet/

      using the receive tab: https://bitcoinelectrum.com/how-to-use-the-electrum-receive-tab/

  30. To sweep or import is simple, for example:
    1) If your Bitcoin address start with “1” and your private key is KwjE8..ā€¦…Nhp8Hq, then write: p2pkh:KwjE8..ā€¦…Nhp8Hq
    2) If your Bitcoin address start with “3” and your private key
    is KwjE8..ā€¦…Nhp8Hq, then write: p2wpkh-p2sh:KwjE8..ā€¦…Nhp8Hq
    3) If your Bitcoin address start with “bc” and your private key is KwjE8..ā€¦…Nhp8Hq, then write: p2wpkh:KwjE8..ā€¦…Nhp8Hq

  31. I’m getting the ‘no inputs….’ message when I sweep too. Trying to sweep from coinbase wallet and have got the WIF’s from bitaddress.org. Tried compressed/uncompressed and all the switches. Any idea what the issue might be?

    1. What do you mean that you are trying to sweep from coinbase wallet and then you also say you got the private keys from bitaddress.org? So which is it? coinbase wallet or bitaddress.org? To restore your coinbase wallet in electrum it is better if you use the seedwords according to the guide below:

      https://bitcoinelectrum.com/restoring-your-standard-wallet-from-seed/

      Make sure you check bip39 in step 4 and select the correct derivation path in step 5. If you have more than one address type in your coinbase wallet you will have to restore each type in a separate wallet file.

  32. hey

    i have following issue

    i have a privat key which starts with L ( its from 2014 ) and i took the private key from the blockchain.com wallet ( previously info )

    so what i have read is that if it starts with L its compressed so i need to uncompress it.

    If i uncompress it will it work 100% and i have access to the bitcoins or not?

    Because i have read that private key is linked to 2 public adresses or something and if the uncompressed priv key is for the second adress which doesnt hold my funds then i dont have access?

    1. Just enter it as it is in electrum and see if electrum finds your coins. If that doesn’t do it you’re going to have to decompress it. Reply back here and I’ll tell you how to do that.

  33. I would like to keep my bitcoins only in paper form. To make a transaction, I need a wallet in the form of a program. I chose Electrum because of the good reviews. Electrum was installed with the Polish localization, so the option descriptions may not be 100% consistent with the English version.
    I generated a pool of public/private addresses from bitaddress.org. I purchased BTC to one of the addresses in a machine such as ATM (bitomat.com).
    In Electrum I created a wallet ‘Import Bitcoin addresses or private keys’. I imported public addresses. The amount is visible on the address where I bought Bitcoins.
    I wanted to test transfer Bitcoins from one address to another.
    I highlighted the address where I have Bitcoins and selected the option: ‘Wallet | Public keys | Sweep’, entered the private key and selected the destination address. I got the message:
    ā€˜This wallet is only being watched. This means you won’t be able to spend your bitcoins. Please make sure you have the seed cipher or private keys before requesting bitcoins to be sent to this wallet.’
    I chose the cheapest option ‘Static’ and pressed ‘Finish’.
    Unfortunately, nothing happened. What am I doing wrong?

  34. It says mini private key format is supported, Iā€™d like to sweep 30-character S-starting one but itā€™s not recognised. Do I need to convert it into some other format, if so, how? Thank you.

    (sorry, looks like I posted to the wrong place)

    1. Mini private keys are supported by electrum. It probably does not pass the checksum test that is designed to detect typographical errors. Make sure you are entering it correctly. All characters must be present with the correct capitalization.

  35. I believe I have used the Sweep functionality in the Electrum wallet and the funds were transferred to a new BTC address which is supposed to be controlled by the wallet. The thing is that I do have the seed phrase and the private keys, I can restore the wallet from any of these but I still see a balance 0 in my wallet. What can be done?

    If it helps I can provide the initial BTC address were the funds were available, the tx id and the address were the funds were transferred after sweep

    1. Go to view menu > check “addresses”, switch to addresses tab, press ctrl+f and paste in the address where the coins were sent. Does the address show up in the list of addresses? If it does then make sure you are connected to an electrum server. There should be a green or blue orb in the bottom right. If it’s red then that means you are not connected to a server. You can then try switching servers:

      https://bitcoinelectrum.com/how-to-switch-to-a-different-electrum-server/

Leave a Reply to Abdussamad Cancel reply

Your email address will not be published. Required fields are marked *