PyWallet-GSC installation and compatibility

Identify your Bitcoin wallet file, then set up PyWallet-GSC on Ubuntu or Windows Subsystem for Linux (WSL). You can verify the installation before you bring any wallet data into the workspace.

Wallet format compatibility

Bitcoin Core has used wallet.dat for both Berkeley DB and SQLite wallets. The filename alone cannot tell you which database you have. If you’re unsure which app made the backup, check where it came from and identify the format on a working copy first.

Bitcoin wallet file formats and documented recovery behavior
Wallet file What to expect
Legacy Berkeley DB PyWallet-GSC looks for known wallet records. If the wallet is encrypted, keep the original passphrase available.
SQLite descriptor wallet PyWallet-GSC recognizes the format and looks for possible keys in some records. Treat the output as candidates until you can match them to known addresses. A full restore also needs the wallet’s descriptors.
Corrupted wallet file If a readable backup exists, try that copy first. Scanning a damaged copy may find fragments, depending on which records survived.

A forgotten wallet passphrase and a missing seed word are different problems. Find options for each in the Bitcoin wallet recovery tools comparison.

Restore an intact backup with Bitcoin Core

For an intact backup made by Bitcoin Core, start with its wallet restore documentation if your version supports loading the format. Restoring the wallet as a whole avoids exporting individual private keys.

Bitcoin Core 30 and later use a migration step for legacy Berkeley DB wallets. Use a supported, updated release and keep separate backups before migrating. Bitcoin Core 30.0 and 30.1 had a migration bug that could delete wallet files.

After restoring, select the restored wallet by name. Give Bitcoin Core time to finish syncing and scanning before judging the balance or transaction history. If activity is still missing, compare the wallet’s addresses or transactions with your own records and check any warnings from the restore. Bitcoin Core reports the wallet name and scan progress in getwalletinfo.

Install on Ubuntu or WSL

The project documents testing on Ubuntu 24.04 and lists setup steps for Ubuntu under WSL. On Windows, start with Microsoft’s WSL installation guide, then open the Ubuntu terminal to run the PyWallet-GSC setup. Run python3 --version there to confirm Python 3 is available.

Set up the project in your Ubuntu home directory if you’re using WSL. The path begins with /home/. Paths beginning with /mnt/c/ point to the Windows drive. Keep your working wallet copy and output in a private folder outside any sync service.

  1. Get the source from the PyWallet-GSC repository. Record the commit so you can refer to the same code and instructions later.
  2. Open a terminal in the project folder. Run chmod +x install.sh and then ./install.sh to set up the Ubuntu packages and Python environment. The repository also has manual installation instructions.
  3. Run source pywallet_build_env/bin/activate in that terminal. Check the Python dependencies with python3 -c "import bsddb3, ecdsa, Crypto". The command returns to the prompt quietly when all three imports work.
  4. From the same environment and project folder, run python3 pywallet.py --help to make sure the program starts without using a wallet file.

These checks confirm that the software starts and Python can load the tested modules. Wallet compatibility still depends on the file you have. Finish downloading the code and dependencies before disconnecting from the network to work with a wallet.

Troubleshoot installation errors

Ubuntu reports an externally managed environment
Follow the virtual environment steps in the README. After activation, command -v python3 should show a path inside pywallet_build_env. Run the dependency check again from that terminal.
The bsddb3 installation fails
If the error mentions a missing Berkeley DB header or a compiler, check the Ubuntu system package list in the README. It includes libdb-dev, python3-dev, and build-essential.
The runner cannot find its virtual environment
Run the script from the project folder that contains pywallet_build_env. If the folder is missing, finish the installation there first.

If the dependency check and help command work, but extraction fails, see the wallet.dat recovery guide for file checks and help interpreting the output.