AdGuard Home blocks adverts and trackers for every device in your house at once, by answering their DNS lookups. Point your router at it and phones, laptops and smart TVs are covered without installing anything on them.
On this page
Good to know before you install
Turning on 'Route this server's own DNS through AdGuard' sends the whole server's lookups through AdGuard, so its filtering and privacy cover the host as well as the devices you point at it. On a machine running a VPN such as Mullvad that manages its own DNS, or one that needs split DNS, it can conflict, so it is best on a dedicated or headless box. It is off by default and turning it off, or uninstalling AdGuard, puts the server's resolver back exactly as it was.
At a glance#
- What it is
- DNS based Ad Blocking Networking
- Where it opens
- Admin Interface
On its own port at
http://your-server:port, oradguard.your-domainonce you have a domain - Updates
- Automatic A backup is taken first, and it rolls back if the update fails
- Backups
- Included Part of the daily backup when that's switched on
- Copies
- One per server
What it's good for#
Every time a device opens a website or an app phones home, it first asks a DNS server where that name lives. AdGuard Home is a DNS server with a long list of advertising and tracking names it simply refuses to look up. The advert never loads, because the device never finds out where it lives. That works for things you can't install a blocker on, like a smart TV or a games console, and it works for every browser on every phone.
It also keeps a log of which device asked for what, which is an eye-opener the first time you look at it, and lets you block or allow names by hand.
On LibrePortal it does one more job: it answers for your own apps. When you have a domain or local names switched on, LibrePortal tells AdGuard to point those names at your server's address on your home network, so they open directly at home instead of going out to the internet and back.
AdGuard Home or Pi-hole?
Pi-hole does the same job. AdGuard Home has a more modern admin page and handles every local name with a single wildcard entry; Pi-hole has a long history and a very large community. Pick one: they both want port 53, so running both on one server leaves one of them unable to serve your devices.
Signing in#
Open AdGuard with the Admin Interface button on its page. LibrePortal finishes AdGuard's setup wizard for you during the install, so you never see it: the account is called admin, and its password is in the Login Details shown when the install finishes. Press Welcome on the app's page to see it again.
If you've given AdGuard a domain, its admin page there also sits behind LibrePortal's website login (the Traefik one), so you'll be asked for that first. Both sets of details are on the same card.
A brand new AdGuard answers with its setup wizard, and whoever finishes the wizard first sets the admin account. So LibrePortal keeps AdGuard reachable from the server only while it fills the wizard in, and opens it up once it has checked the new login works (why). Nobody gets a chance to reach the wizard first.
If the install couldn't finish the wizard
If the login couldn't be checked, the install says so and leaves AdGuard reachable from the server only, so nobody else can finish the wizard. The simplest fix is to uninstall it and install it again. Only restart it to open it up once you know the login on the card works.
To change the password, use Reset Admin Password on the Tools tab rather than AdGuard's own settings, so LibrePortal keeps being able to add your local names. Leave the box empty and a strong one is made for you. The new password goes straight onto the Login Details card, and it's printed in the task's output too.
If you reset the password with 0.4.6 or earlier, the card kept showing the old one. The first time AdGuard starts after the update to 0.4.7, LibrePortal checks which password AdGuard really accepts and puts that one on the card. It doesn't change anything in AdGuard itself.
Getting your devices to use it#
AdGuard only filters for devices that ask it. The end of the install tells you where its DNS server is, something like "AdGuard's DNS server is on 192.168.1.50, port 53".
- Check it's on port 53. Routers and devices can only use a DNS server on port 53; there's nowhere to type a port number. If the install says it's on another port, see When port 53 is taken below.
- Set your router's DNS to your server's address. Look for "DNS" in your router's network or DHCP settings and put your server's address, like
192.168.1.50, as the only DNS server. Every device picks it up the next time it reconnects. - Or try it on one device first. Set the DNS server in that device's network settings instead, and see how you get on before switching the whole house.
Don't add a second DNS server beside it
If you give your router AdGuard plus a public DNS server "as a backup", devices use whichever answers first, and adverts leak through. Worse, your local names stop working half the time. Use AdGuard alone.
AdGuard's DNS port is for trusted places only: your home network, the addresses you've trusted, and your VPN devices. That's deliberate. A DNS server open to the whole internet gets found within hours and used to attack other people.
When port 53 is taken#
On a stock Ubuntu server, a part of the system called systemd-resolved already sits on port 53, and if Pi-hole is installed it has 53 too. Rather than fail, the install puts AdGuard's DNS on one other port (the same one for TCP and UDP), tells you what's holding 53 and how to free it, and carries on. AdGuard works, but nothing on your network will use it until it has port 53.
Once you've freed port 53 (turned off systemd-resolved's stub listener, or removed Pi-hole), run Use Port 53 for DNS on the Tools tab. It checks 53 really is free, moves AdGuard onto it and redeploys it; DNS through AdGuard pauses for a few seconds while that happens. If something still holds 53, it refuses and says what.
Everyday use#
The first things most people do in AdGuard's own admin page:
-
Query Log shows every lookup and which device made it. If a site or app breaks, look here for what was blocked just then, and unblock it from the log entry.
-
Filters is where the blocklists live. The defaults are a good start; you can add more, and allow names that a list blocks by mistake.
-
Settings → DNS settings is where AdGuard sends the lookups it doesn't block. If you also run Unbound on this server, AdGuard uses it as its upstream by itself: Unbound is offered beside AdGuard under Also install, and whenever it's installed LibrePortal points AdGuard's upstream at it, so your lookups go straight to the internet's own name servers instead of a public resolver. It only ever changes an upstream nobody chose, so if you've set your own it leaves it alone and tells you how to switch to Unbound by hand. Remove Unbound and the default upstream comes back.
Without Unbound, LibrePortal sets an encrypted upstream (DNS-over-HTTPS): Mullvad's by default, or Quad9 or Cloudflare if you choose that under Upstream DNS (encrypted) on the Config tab. custom leaves AdGuard's own setting alone. See DNS for your VPN.
LibrePortal's own entries show under Filters → DNS rewrites: one wildcard per domain (and one for your local names), pointing at your server. LibrePortal only ever removes entries it added itself, so anything you add there by hand is left alone, even an entry identical to one it would have made. It refreshes them after every app install and every domain change. To add names of your own that survive everything, use libreportal dns records add: see Your own records.
This server's own DNS#
AdGuard filters the devices you point at it. By default the server it runs on is not one of them: it keeps using whatever DNS it was set up with, so AdGuard going down can never leave the server itself unable to look anything up.
You can change that. Route this server's own DNS through AdGuard (in AdGuard's advanced settings on the Config tab) sends the server's own lookups through AdGuard too, so the blocking and privacy cover the server, not just your devices. It's off to start with, and reversible: turn it off, or uninstall AdGuard, and the server's DNS goes back exactly as it was. LibrePortal points it at AdGuard on the server's own loopback address, never its network address, so a full-tunnel VPN like Mullvad can't pull the answers through the tunnel, and it checks AdGuard really answers before switching anything over.
Best on a box that does nothing else
Routing the whole server's DNS through AdGuard can clash with a VPN or with split DNS, which both want a say in how the server looks names up. So it suits a dedicated or headless box, where AdGuard is the server's whole job, better than a machine you also use as a desktop. On an everyday machine, leave it off and point your other devices at AdGuard instead.
Refresh Local DNS on the Tools tab is a different thing: it re-applies AdGuard's records for your app names, so they point at the server on your network. It doesn't touch the server's own resolver. You rarely need it; LibrePortal refreshes those records by itself whenever you install an app or change a domain.
Good to know#
- Updates are automatic, with a backup taken first, and it rolls back if the update fails.
- Backups include its settings file and its working data, including the query log and statistics.
- One per server. Devices point at an address, not a port, so a second copy would serve nobody.
- The query log hides full device addresses. The install switches on AdGuard's option to anonymise client addresses, so the log and statistics keep only part of each one. Installs made with 0.4.6 or earlier tried to and it never took, so on an older install check AdGuard's query log settings if that matters to you.
- It can filter on the move, through the VPN. Keep the DNS ports private rather than opening them to the internet. By default the LibrePortal VPN doesn't hand your devices a DNS server, so a phone on the move isn't filtered. But turn on Use this server's names for a phone on the VPN (which is offered only while AdGuard or Pi-hole is installed, exactly so there's something to answer) and all its lookups go through the server, so AdGuard filters it while you're out too. See names over the VPN and DNS for your VPN.
Addresses and ports#
AdGuard has 6 ports. LibrePortal picks a free port number for each when you install, so yours will differ from anyone else's. The Config tab's Network section shows them, and the app's Open button uses the right one. "Anyone" means it's reachable from wherever your server is reachable; you can make it private later.
| What it is | Who can reach it | With a domain |
|---|---|---|
| Admin Interface | Anyone | adguard.your-domain |
| DNS Server (TCP) TCP | Trusted places only | Port only |
| DNS Server (UDP) UDP | Trusted places only | Port only |
| Alternative DNS TCP | Off until you turn it on | Port only |
| DNS-over-TLS TCP | Off until you turn it on | Port only |
| Metrics Exporter (sidecar, docker-network only) TCP | Off until you turn it on | Port only |
Settings#
These are AdGuard's own settings on its Config tab. The settings every app shares, like backups, updates and where its data lives, are explained in App pages and settings.
| Setting | What it does | Starts as |
|---|---|---|
| AdGuard Admin Username | Username for the AdGuardHome admin web UI | Empty |
In its config file#
A few more aren't on the Config tab yet. They live in the app's config file, described here so you know they exist. How to change them.
| Setting | What it does | Starts as |
|---|---|---|
NameCFG_ADGUARD_DISPLAY_NAME |
What this app is called on your dashboards. Leave empty to use its usual name | Empty |
Show on the LibrePortal DashboardCFG_ADGUARD_SHOW_ON_DASHBOARD |
Whether this app gets a shortcut on the front page of the LibrePortal WebUI, separate from any Dashy dashboard Choices: true, false |
false |
Upstream DNS (encrypted) AdvancedCFG_ADGUARD_UPSTREAM |
Where AdGuard looks up names it doesn't block, over an encrypted connection; Unbound is used instead when installed, and custom leaves AdGuard's own setting alone. Choices: mullvad, quad9, cloudflare, custom |
mullvad |
Route this server's own DNS through AdGuard AdvancedCFG_ADGUARD_HOST_DNS |
Also sends the server's own lookups through AdGuard, so its blocking and privacy cover the host; best on a dedicated/headless box (see the note). Choices: true, false |
false |
Update checkCFG_ADGUARD_UPDATE_CHECK |
Whether AdGuard Home may ask AdGuard's servers about newer versions. Choices: true, false |
false |
Query log kept forCFG_ADGUARD_QUERYLOG_HOURS |
How many hours AdGuard keeps the list of names each device asked for. Shorter is more private; the log is how you see what got blocked. Choices: 1, 6, 24, 168, 720, 2160 |
24 |
Statistics kept forCFG_ADGUARD_STATS_DAYS |
How many days AdGuard keeps its totals and charts. Choices: 1, 7, 30, 90 |
7 |
Tools#
AdGuard's Tools tab has 3 buttons for jobs you'd otherwise need a terminal for. Each one runs as a task, so you can watch it on the Tasks page and read what it did. More about Tools.
Set a new admin password. Leave blank to generate one.
Move AdGuard's DNS server to port 53, where devices and routers can use it. Only works once nothing else on this server holds port 53.
Re-apply AdGuard's local DNS rewrites so this server's app names resolve to it on your network. Does not change the server's own DNS resolver.
Works with#
These are the other apps AdGuard knows how to work with. Once it's installed, its page shows the same list with whether each one is connected. How this works.
- Upstream resolver: Looks names up through Unbound, so no outside resolver sees them. LibrePortal sets this up by itself when both are installed.
- Grafana: Shows dashboards for the apps that have one. works with every app
- Home Assistant: Shows ad-blocking statistics and a switch to pause it.
- Prometheus: Collects metrics from the apps that can export them. works with every app
- Uptime Kuma: Watches your apps and shows when one goes down. works with every app
Privacy and security#
All clear AdGuard Home blocks ads and trackers for your whole network and collects no usage statistics. It downloads only the blocklists you choose.
What leaves this server#
- Blocklists you enable are downloaded from their publishers
- Your lookups go to the encrypted DNS provider you pick (Mullvad by default), or to Unbound if it is installed
- Safe Browsing and Parental Control, if you switch them on, send hashed domain prefixes to AdGuard
What LibrePortal turns off#
- Query history longer than 24 hours and statistics longer than 7 days (switchable in Config)
- Update check against AdGuard's servers (switchable in Config)
Licence: GPL-3.0. Audited: 21 October 2026. See the privacy of every app and the Promise.
Sources#
Under the hood#
- It runs this image:
adguard/adguardhome:v0.107.79@sha256:aba9e3bf0613be3ba3755e1fc311b126e2c24bec25e18b6483894a88283074f0. - It can sit behind Authelia's sign-in once Authelia is installed.
- Its own project and documentation: github.com/AdguardTeam/AdGuardHome
Ports, settings, tools and connections on this page are read from LibrePortal v0.10.97's app catalogue each time the guide is built.