Anjan Nair
Anjan's Blog


Anjan's Blog

Pi-hole with Raspberry Pi 3

Pi-hole with Raspberry Pi 3

Setup a Raspberry Pi 3 to be a Pi-hole server for your network and block ads and trackers.

Anjan Nair's photo
Anjan Nair
·Aug 10, 2022·

2 min read

Play this article

Table of contents

  • Installing Pi-hole
  • Ad-lists
  • DNS over HTTPS (DOH)

A pi-hole is basically a black-hole for internet ads. The project is an open source ad blocking software at the DNS level.

Installing Pi-hole

The easiest way of installing Pi-hole is by running the following script

curl -sSL | bash

The script will do everything to install the software and convert your Raspberry Pi into a pi-hole.

Once done, you can open the web interface of the pi-hole. The web interface is simple to understand and easy to setup too.

Finally before moving on we set the DNS of our router to the IP address of our pi-hole.


To add lists apart from the one used at setup we go to Group Management>Adlists

My preferred lists are -

1) Normal Hosts -

2) Adguard List -

3) EasyList -

4) Privacy -

5) Windows Spyware -

6) Anti-Malware List -

7) Threat Intel by OSINT -

8) Adult sites -

You can add all this together by adding the URLs separated by space. After doing so make sure to update the Gravity list by running pihole -g command or by heading to Tools and Update Gravity. This downloads the list and updates it.


To setup DNS over HTTPS on your pi-hole we use the docs given in the official website here.

Note - Go with the manual method as the automatic did not work for me.

Share this