Run the Pi-hole installer
Open Terminal on your Pi or connect via SSH
then run wget -O basic-install.sh https://
install.Pi-hole.net . Next run sudo bash basicinstall.sh to launch the installer. The program will automatically check for installed packages and ask you to confirm you want to install a network wide blocker. Press Return to confirm, then once again on the next screen.