Inside Bitcoin
Opening the selected file…
Opening the selected file…
The code behind the network, with room to understand it.
Release published 2026-10-28 · Snapshot fetched 2026-11-01. Latest stable release at fetch time; development branches and Git history are excluded. Only the selected code window and visible folders load here.
1WINDOWS BUILD NOTES2====================4Below are some notes on how to build Bitcoin Core for Windows.6The options known to work for building Bitcoin Core on Windows are:8* On Linux, using the [Mingw-w64](https://www.mingw-w64.org/) cross compiler tool chain.9* On Windows, using [Windows Subsystem for Linux (WSL)](https://learn.microsoft.com/en-us/windows/wsl/about) and Mingw-w64.10* On Windows, using [Microsoft Visual Studio](https://visualstudio.microsoft.com). See [`build-windows-msvc.md`](./build-windows-msvc.md).12Other options may work, but are not officially tested:14* On Windows, using a POSIX compatibility layer application such as [cygwin](https://www.cygwin.com/) or [msys2](https://www.msys2.org/).16The instructions below work on Ubuntu and Debian. Make sure the distribution's `g++-mingw-w64-x86-64-posix`17package meets the minimum required GCC version specified in [dependencies.md](dependencies.md).18If compiling with the GUI (default in depends), at least GCC version 13 is required.20Installing Windows Subsystem for Linux21---------------------------------------23Follow the upstream installation instructions, available [here](https://learn.microsoft.com/en-us/windows/wsl/install).25Cross-compilation for Ubuntu and Windows Subsystem for Linux26------------------------------------------------------------28The steps below can be performed on Ubuntu or WSL. The depends system29will also work on other Linux distributions, however the commands for30installing the toolchain will be different.32See [README.md](../depends/README.md) in the depends directory for which33dependencies to install and [dependencies.md](dependencies.md) for a complete overview.35If you want to build the Windows installer using the `deploy` build target, you will need [NSIS](https://nsis.sourceforge.io/Main_Page):37apt install nsis40Acquire the source in the usual way:42git clone https://github.com/bitcoin/bitcoin.git43cd bitcoin45Note that for WSL the Bitcoin Core source path MUST be somewhere in the default mount file system, for46example /usr/src/bitcoin, AND not under /mnt/d/. If this is not the case the dependency autoconf scripts will fail.47This means you cannot use a directory that is located directly on the host Windows file system to perform the build.49Build using:51gmake -C depends HOST=x86_64-w64-mingw32 # Append "-j N" for N parallel jobs.52cmake -B build --toolchain depends/x86_64-w64-mingw32/toolchain.cmake54Run `cmake -B build -LH` to see the full list of available options.56cmake --build build # Append "-j N" for N parallel jobs.58## Depends system60For further documentation on the depends system see [README.md](../depends/README.md) in the depends directory.62Installation63-------------65After building using the Windows subsystem it can be useful to copy the compiled66executables to a directory on the Windows drive in the same directory structure67as they appear in the release `.zip` archive. This can be done in the following68way. This will install to `c:\workspace\bitcoin`, for example:69```shell70cmake --install build --prefix /mnt/c/workspace/bitcoin71```73Note that due to the presence of debug information, the binaries may be very large,74if you do not need the debug information, you can prune it during install by calling:75```shell76cmake --install build --prefix /mnt/c/workspace/bitcoin --strip77```79You can also create an installer using:80```shell81cmake --build build --target deploy82```
Independent explanations by MyBitcoinExplorer. Not affiliated with or endorsed by Bitcoin Core. Guides are educational and do not replace the source or its tests.
Bitcoin Core source © its contributors, distributed under the MIT license. Original notices and bundled third-party licenses are retained in the source tree.