Install script to help Pi-hole run semi-natively under Windows 10/11 and Server 2019/2022 by leveraging the Windows Subsystem for Linux, renamed later to WSL1. Because WSL1 does not require a hypervisor and full Linux kernel it's the most lightweight way to run Pi-hole on Windows. Pi-hole and associated Linux binaries are visible in Task Manager right alongside your Windows apps (See Windows 11 screenshot above.)
Gravity Sync.cmd
and copy/paste the command into the console of another Debian or Ubuntu-based Pi-hole.lsof
to ss
for port and service checking. Now a wrapper for ss
on WSL1 reformats the output of netstat.exe
into something Pi-hole can work with.Pi-hole System Update.cmd
, Pi-hole Gravity Update.cmd
, and Pi-hole Web Admin.cmd
There is no endorsement or partnership between this page and Pi-hole© LLC. They deserve your support if you find this useful.
Pi-hole for Windows can be used to block ads and encrypt DNS queries for your local Windows PC or entire network. If you use it to serve DNS for your entire network, it's highly recommended you install a second Pi-hole instance on your network, and enable Gravity Sync to ensure DNS is constantly available should your Windows PCs need to reboot for any reason.
Pi-hole for Windows is a great way to upcycle old hardware. If you have a Windows PC, tablet, or HDMI stick with 1GB RAM and it can boot Windows 10 x64 you are good to go. If you don't have a Windows license, Hyper-V Server 2019 works and is a free download from Microsoft.
Download and configuration steps complete in 2-15 minutes, depending on your hardware and antivirus solution. If Windows Defender is active the installation will take longer. Some users have reported issues with other antivirus products during installation.
/bin/ss
along with other fix-ups for WSL1 compatibility.After the install completes, the Scheduled Task needs to be configured for auto-start at boot (before logon).
DHCP Server is not supported and is disabled in the Pi-hole Web UI.
IPv6 DNS now works in addition to IPv4.
Default location for Pi-hole install is C:\Program Files\Pi-hole
. This folder contains utilities to update or modify your Pi-hole:
Pi-hole System Update
🠞 pihole -upPi-hole Configuration
🠞 pihole -rPi-hole Gravity Update
🠞 pihole updateGravityTo completely uninstall Pi-Hole, open the Pi-hole install folder in Windows Explorer. Right-click Pi-hole Uninstall.cmd
and click Run As Administrator. If you are uninstalling or reinstalling and need to retain your Pi-hole's configuration, export it first via the Pi-hole Teleport feature located in the web interface.