Bitcoin Core Wallet.dat Recovery: How to Restore an Old Wallet File

Blog » Bitcoin Core Wallet.dat Recovery: How to Restore an Old Wallet File
Updated on Sep 1, 2026
Author: Robbert Bink
Detektiv mit Crypto Recovers-Abzeichen hält einen alten Schlüssel und entsperrt ein Bitcoin Core-Tresor, während er auf seinem Laptop arbeitet.

You found a wallet.dat file. Maybe it was on an old hard drive you pulled from a drawer, in a backup folder you had forgotten about, on a USB stick labelled something cryptic, or buried in a cloud archive from 2013. You know it might contain Bitcoin. You do not know how to open it, whether it is encrypted, or how much is inside. This guide walks through every step from file to funds.

What wallet.dat Actually Is

Every Bitcoin Core installation stores its wallet data in a file called wallet.dat. This file contains the private keys that control your Bitcoin addresses, along with transaction history and metadata. The file is the wallet. If you have wallet.dat, you have the keys to whatever Bitcoin was sent to those addresses, provided you can unlock it.

Legacy wallet.dat files use the Berkeley DB (BDB) format, a database engine that was standard in the early 2000s. Bitcoin Core versions from 0.21 onward introduced a new descriptor wallet format using SQLite, but the vast majority of old wallet files in the wild are still BDB. The file format matters for recovery, because BDB files have specific corruption patterns and recovery techniques that differ from newer formats.

Not every old Bitcoin Core wallet relies on a wallet.dat file for backup. If yours was set up with a recovery phrase instead, the process is different; see our guide on the Bitcoin Core seed phrase for the distinction.

Step 1: Make Copies Before Doing Anything Else

Before you open, move, or attempt anything with your wallet.dat, make at least two copies and store them in separate locations. Copy the file to a different drive, a USB stick, or a cloud service you trust. The original file should be treated as the master copy: do not run recovery tools on it, do not open it with a fresh Bitcoin Core installation, and do not rename it. Work only with copies from this point forward.

This is not optional caution. A damaged or overwritten wallet.dat cannot be undone, and some recovery attempts can write to the file in ways that make later attempts harder. Start with copies, always.

Step 2: Check Whether the Wallet Contains Funded Addresses

Before investing time in password recovery or file repair, find out if there is any Bitcoin in the wallet. If the file is not encrypted, you can load it into Bitcoin Core and check. If it is encrypted, or if you cannot open it, there is a faster route: extract the public addresses from the file (even encrypted wallet.dat files store public keys in readable form) and look them up on a block explorer like blockchain.com or mempool.space.

If the addresses show a balance, the file is worth working on. If every address shows zero or only old transactions that were already spent, the wallet is empty and no password recovery will change that. Knowing this upfront saves you from spending days or weeks on a case with no payoff.

Step 3: Load the Wallet in Bitcoin Core

If the file is not corrupted and not encrypted, the simplest path is to load it directly into Bitcoin Core. Install the version of Bitcoin Core that matches the era of the wallet file, or a recent version (which supports legacy BDB wallets). Place the wallet.dat file in Bitcoin Core’s data directory (the default is ~/.bitcoin/ on Linux, ~/Library/Application Support/Bitcoin/ on macOS, and %APPDATA%\Bitcoin\ on Windows), start Bitcoin Core, and let it load.

Bitcoin Core will scan the blockchain for transactions associated with the keys in the wallet. This requires either a fully synced node (which can take days or weeks to download initially) or a pruned node with a rescan. If you just want to check balances and move funds, you do not need a full node: you can extract the private keys and import them into a lighter wallet.

Step 4: Handle Encryption

If Bitcoin Core asks for a password when you try to send funds or export keys, the wallet is encrypted. This is the most common barrier with old wallet.dat files: the owner set a password in 2012, forgot it, and now cannot access the private keys inside.

You can still see the wallet’s balance and addresses without the password, because public key data is stored in cleartext. But spending requires the private keys, which are locked behind the encryption. For a full guide on recovering the password, see our article on Bitcoin Core password recovery. If you want to understand the brute-force process in more depth, our wallet.dat password recovery guide covers the technical details.

Have a wallet.dat file you cannot open?

Crypto Recovers has recovered more than 200 wallets since 2019, many of them old Bitcoin Core files with forgotten passwords. Free assessment, No Cure No Pay.

Recovering a Deleted wallet.dat

If the wallet.dat file was deleted from the computer, all is not necessarily lost. When an operating system deletes a file, it typically removes the filesystem entry that points to the data, not the data itself. The actual content remains on the drive until the sectors it occupied are overwritten by new files.

On a traditional spinning hard drive (HDD), deleted wallet.dat data can survive for months or years, especially if the drive has not been heavily used since the deletion. On a solid-state drive (SSD), the situation is worse: SSDs use a process called TRIM that proactively clears deleted data to maintain performance, which means the window for recovery is much shorter.

If you suspect a wallet.dat was deleted from a drive, stop using the drive immediately. Do not install software on it, do not save files to it, and ideally do not even boot from it. The goal is to preserve whatever data remains in unallocated space. File carving tools can search the drive for wallet.dat signatures and attempt to reconstruct the file from fragments. This is specialised work, and the success rate depends heavily on how much the drive has been used since the deletion.

Dealing with a Corrupted wallet.dat

Corruption typically happens when Bitcoin Core is shut down improperly (a power failure, a system crash, a force-quit during a write operation) or when the drive develops bad sectors. The symptoms vary: Bitcoin Core may refuse to start, show a database error, crash on load, or display incorrect balances.

Bitcoin Core has a built-in salvage mode that attempts to recover data from a damaged wallet.dat. You can start it with the -salvagewallet flag. This does not always work, and it modifies the file, which is why you should only run it on a copy.

If salvage mode fails, the raw key data inside the file may still be intact even though the database structure is damaged. Extracting private keys directly from the binary data, bypassing the database layer, is a technique that requires specialised tools and experience with the BDB file format. This is one of the scenarios where professional recovery makes the most difference.

Extracting Private Keys Without a Full Node

If you do not want to download the entire blockchain (currently over 500 GB), you can extract private keys from an unencrypted wallet.dat and import them into a lighter wallet. The Bitcoin Core console command dumpwallet exports all private keys to a text file. You can then import individual keys into Electrum, Blue Wallet, or another SPV wallet that does not require a full blockchain download.

If the wallet is encrypted, you need the password before you can export anything. There is no shortcut around this: the encryption covers the private keys specifically, and no export command works without decrypting them first.

Old wallet.dat, no password, not sure what to do?

Contact us for a free assessment. We will check whether the file is recoverable and what the next steps are.

FAQ

Can I open a wallet.dat file without Bitcoin Core?

Yes, in some cases. Tools like pywallet can read wallet.dat files and extract keys without a full Bitcoin Core installation. However, these tools require some command-line comfort. For encrypted wallets, you still need the password regardless of which tool you use.

I have a wallet.dat from 2010. Will it work with the latest Bitcoin Core?

Yes. Recent versions of Bitcoin Core support legacy BDB wallet files from any era. You may see a prompt to migrate the wallet to the newer descriptor format, but the old format is still fully supported for loading and spending.

How do I know if my wallet.dat is encrypted?

Load it in Bitcoin Core and try to send a small amount or export a private key. If Bitcoin Core asks for a passphrase, the wallet is encrypted. You can also check the Bitcoin Core title bar or Settings menu: encrypted wallets typically show a lock icon or an “Encrypt Wallet” option that is greyed out.

Someone is selling a wallet.dat with Bitcoin inside. Should I buy it?

No. This is a well-known scam. Either the seller keeps a copy of the keys and drains the wallet after you pay, or the advertised balance was never real. Legitimate Bitcoin wallets are not sold, because anyone with the keys can spend the coins before the buyer does.

Clear agreements before work begins. Before recovery work begins, both parties sign a service agreement setting out the assignment, fees, responsibilities, confidentiality and data handling. At your request, an NDA can also be signed before confidential details about your case are discussed.

Non-custodial wallet access recovery. Your wallet remains yours. We do not hold, manage or transfer your crypto-assets on your behalf. After a successful recovery, you move your funds to a new wallet yourself and pay the agreed success fee separately.

Robbert

Robbert Bink

Founder & CEO

Robbert Bink is the founder and a wallet recovery specialist at Crypto Recovers. He has more than 15 years of experience in programming and IT and has specialized in crypto wallet access recovery since 2019. Through Crypto Recovers, he helps rightful owners securely and efficiently regain access to inaccessible wallets.

Other Blogs by Crypto Recovers