How to Install Pi-hole in Pi Zero

Table of Contents

Pi-hole is a network-wide ad blocker. This will block Ads to all devices connected to your home network without having the need to install ad blocker in each device. Pi-hole can run on multiple devices ranging from Pi Zero to servers. Try to select a device which you can run 24/7, If you are worried about power usage then Pi zero might be the best option. In this article we will see the steps to install Pi-hole in Pi Zero.

Step 01 : Get Pi Zero & Required Accessories

  • You would need following for this install

    • Pi Zero W
    • 5V Power Supply
    • SD Card with Operating System
    • USB OTG Cable
    • Mini HDMI to HDMI Adapter
    • Raspberry Pi Zero Case (Optional)
    • Keyboard and Mouse (Optional, if you already have one)
  • Instead of getting the individual items you could also get the kit with these accessories from CanaKit

Step 02 : Initial Setup

  • Insert the SD card into the SD Card slot

  • Connect the Pi Zero W to all accessories as shown below

  • Device will boot up and will ask you to install an operating system. If you need more operating system choice then click on Wifi Networks and connect to your network

  • Successful connection to WiFi will bring in additional operating system options as shown below, Select the OS you like and proceed with the installation. In this case I choose Raspbian Full

  • Select Yes on the warning message

  • Install will take few minutes to finish. You should see below message after the install finishes

  • At this point the desktop will boot up. In the configuration do the following

    • Give an Hostname for your Pi Zero
    • Enable SSH
  • Open Terminal session and install xrdp for RDP access

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install xrdp

Step 03 : Install Pi-hole

  • ssh into Pi Zero using putty. User name is pi and password is what you selected during Raspberry Pi Desktop configuration

  • Alternatively you can also RDP into Pi Zero and Install from the terminal. User name is pi and password is what you selected during Raspberry Pi Desktop configuration

  • sudo into root using

    sudo su
  • Install Pi-hole using below command. Refer for any additional information

    curl -sSL | bash
  • Installation will bring up UI with on screen instructions

    • Select Ok as applicable
    • Select your preferred DNS provider. I read good reviews about Quad9 so using it for now as DNS provider
    • Pi-hole needs a static IP, So select Yes to use current network settings as static address
    • Select On for web admin interface, web server and log queries
    • Remember to note down login URL, user name and password for web admin interface does not exist

Step 04 : Configure your router

  • Login into your routers admin console by navigating to in your browser. Here are some default user name and passwords for common router brands. If you have ever changed the password use the updated password to login
Router Brand Login IP Default username Default password
Linksys admin admin
Belkin admin admin
Asus admin admin
Netgear admin password
Synology admin admin
Arris admin password
Zyxel admin 1234
Other Brands admin see tag on your router
  • Navigate to the DNS server in the settings of your router and update it with the static IP of your device with Pi-Hole. This path will vary based on your routers make and model, for netgear devices its Internet –> Domain Name Server (DNS) Address does not exist
  • Save the changes, It may take a minute OR two for your router to apply the new settings

Step 05 : Validate Pi-hole

  • Navigate to Pi-hole admin console at Replace the IP address with the static IP address from your installation.

  • Admin console will show details in dashboard as shown below

Pi-hole has now been successfully installed in your network. Ads to any devices connected to your network will be automatically blocked by Pi-hole. Remember to block ads, a machine with Pi-hole should be always running.

Share this blog:

Related Articles