Fidelitas
Secure. Defend. Trust.

How To: Install DNSFilter with PowerShell Via NinjaONE

29.03.24 09:01 AM By Sean Fairchild


This Article will explain how to install DNSFilter with a PowerShell Script using NinjaONE. 

This will be a headless installation so the end user will not see anything on their display.


1. Select Administration --> Library --> Automation --> Add (upper right corner) --> New Script

2. When the New Script Window Opens, Set the Following Variables:

NAME: DNS Filter - Template

DESCRIPTION: Enter your Description

CATEGORIES: Select your Category

LANGUAGE: Select "POWERSHELL"

OPERATING SYSTEM: Select "Windows"

ARCHITECTURE: Select "64-bit"

3. In the Script Area Paste the Following code and Click Save: (MAKE SURE TO REPLACE $nkey with your  KEY)

$url = "https://download.dnsfilter.com/User_Agent/Windows/DNS_Agent_Setup.msi"
$nkey = "ENTERYOURDNSFILTERSITEKEY"
$msiPath = "$env:TEMP\DNS_Agent_Setup.msi"
Invoke-WebRequest -Uri $url -OutFile $msiPath
Start-Process msiexec -ArgumentList "/qn /i `"$msiPath`" NKEY="`"$nkey`""" -Wait
Remove-Item $msiPath

4. Now the Script is now ready to run on a End Point. 

Select The Device --> Select the "Play" button --> Select "Run Automation" --> Select "Script" --> Select the new script you added.

Wait a minute or so and then check your DNSFilter Dashboard for the new agent


Sean Fairchild

Fidelitas