Success Story: In December 2024, I found an old
wallet.datfile on a backup drive. Using these tools, I successfully recovered 0.12145281 BTC! This project packages everything I learned into an easy-to-use tool so you can do the same.
Have you found an old wallet.dat file and wonder if it contains Bitcoin? This tool helps you:
- Detect if any
.datfile is actually a Bitcoin wallet - Extract all Bitcoin addresses and private keys
- Check current balances across multiple blockchain APIs
- Export private keys for importing into modern wallets
- Transfer your Bitcoin safely to exchanges or hardware wallets
# Clone the repository
git clone https://github.com/yourusername/simple-bitcoin-wallet-recovery.git
cd simple-bitcoin-wallet-recovery
# Install dependencies
pip3 install -r requirements.txt# Scan an entire drive or directory (recommended)
python3 recovery_wizard.py --scandir /mnt/c
# Check a single wallet file
python3 recovery_wizard.py wallet.dat
# Dry run to see what would be scanned
python3 recovery_wizard.py --scandir /path/to/old/backups/ --dry-runCommon locations for old Bitcoin wallets:
C:\Users\[Username]\AppData\Roaming\Bitcoin\(Windows)~/Library/Application Support/Bitcoin/(Mac)~/.bitcoin/(Linux)- Old backup drives, USB sticks, or cloud storage
- Files named
wallet.dator any.datfile from 2009-2017
Recommended: Scan a Directory
python3 recovery_wizard.py --scandir /mnt/cThis will:
- Recursively scan for all .dat files
- Show progress with file count and progress bar
- Analyze each .dat file to identify Bitcoin wallets
- Extract private keys from confirmed wallets
- Check balances across multiple blockchain APIs
- Generate organized output in
bitcoin_recovery_[timestamp]/
Alternative: Check Single File
python3 recovery_wizard.py suspicious_file.datThe tool creates an organized output directory:
bitcoin_recovery_20241229_143022/
βββ output/
β βββ summary_report.txt # Overview of all findings
β βββ funded_wallets/ # Wallets with Bitcoin
β β βββ wallet_001/
β β βββ private_keys.txt # Keys for import
β β βββ TRANSFER_GUIDE.txt
β βββ empty_wallets/ # Wallets without Bitcoin
βββ scratch/ # Temporary files (can delete)
If Bitcoin is found, you'll see:
π SUCCESS! Found 0.12145281 BTC!
π Check bitcoin_recovery_[timestamp]/output/funded_wallets/ for private keys
π See bitcoin_recovery_[timestamp]/output/summary_report.txt for details
- Install Electrum from https://electrum.org
- Create new wallet β "Import Bitcoin addresses or private keys"
- Copy the private keys from
funded_private_keys.txt - Send to your Coinbase/Kraken/hardware wallet
Important: Always send a small test transaction first!
# Scan with progress tracking
python3 recovery_wizard.py --scandir ~/old-computers/
# Dry run to preview what will be scanned
python3 recovery_wizard.py --scandir /mnt/backup --dry-run
# Quiet mode for automation
python3 recovery_wizard.py --scandir /mnt/c --quietfrom lib.secure_exporter import SecureExporter
exporter = SecureExporter()
exporter.export_keys(addresses, format='electrum') # For Electrum
exporter.export_keys(addresses, format='bitcoin_core') # For Bitcoin Core
exporter.export_keys(addresses, format='csv') # Spreadsheetfrom lib.balance_checker import BalanceChecker
checker = BalanceChecker()
balance = checker.check_balance('1YourBitcoinAddress...')- Never share private keys - Anyone with these keys can steal your Bitcoin
- Work offline when possible - Disconnect internet when handling private keys
- Delete files securely after transferring:
# Linux/Mac shred -vfz private_keys_file.txt # Windows cipher /w:C:\path\to\directory
- Use 2FA on any exchange accounts
- Consider a hardware wallet for long-term storage
- Wallet Detection: Analyzes file headers and structure to identify Bitcoin wallets
- Key Extraction: Uses modified PyWallet to extract private keys
- Balance Checking: Queries multiple blockchain APIs for reliability
- Secure Export: Provides keys in formats compatible with modern wallets
- Python 3.7+
- Berkeley DB libraries
- Internet connection for balance checking
sudo apt-get install python3-bsddb3 libdb-dev
pip3 install -r requirements.txtbrew install berkeley-db
pip3 install -r requirements.txtSee detailed Windows instructions
Install Berkeley DB: sudo apt-get install python3-bsddb3
Run with appropriate permissions or check file ownership
- Wallet might be empty (funds already moved)
- Try running again (API rate limits)
- Check internet connection
The tool handles these automatically but checking may take 10-15 minutes
Contributions are welcome! Please see CONTRIBUTING.md
MIT License - see LICENSE
- Original PyWallet by jackjack
- Blockchain APIs: blockchain.info, blockstream.info, blockcypher.com
- The Bitcoin community for years of development
This tool is provided as-is for educational and recovery purposes. Always verify results independently and never trust any single tool with significant funds. The authors are not responsible for any loss of funds.
Found this helpful? Consider starring β the repository!
Recovered Bitcoin? Share your success story (keep amounts private)!
Need help? Open an issue or check existing discussions.