安装向导
在浏览器中打开 AdGuard Home 的后台,进入安装向导,点击 “开始配置”。默认后台地址为:http://IP:3000/
设置网络接口
将后台的访问端口更改为 3000,避免与 NAS 后台的 80 端口发生冲突,DNS 端口保持为 53 即可。
设置管理员账户
完成初始化设置
后期配置
安装完成后,我们还需要进一步的设置,根据需要作出一定的优化。
常规设置
- 过滤器更新间隔:DNS 过滤清单默认更新间隔,一般为 3 天 - 7 天
- 使用 AdGuard “浏览安全” 网页服务:作用与 Chrome 网页安全性检查类似,开启后,当用户访问存在潜在威胁的网站时,AdGuard 会主动拦截并弹出提示
- 使用 AdGuard “家长控制” 服务:如果家中有尚未成年的孩子,建议开启,避免访问不良网站
- 强制安全搜索:隐藏 Bing、Google、Yandex、YouTube 网站上 NSFW 等不适宜的内容
- 查询记录保留时间:AdGuard Home 服务端采用 Sqlite 文件数据库存储日志,长时间保留可能会降低运行速度,同时占用大量的储存空间,家庭用户一般保留 24 小时 - 7 天即可
- 统计数据保留时间:用于仪表盘的数据展示,一般保留 24 小时 - 7 天即可
DNS 设置
- 上游 DNS 服务器:AdGuard Home 的上游 DNS 服务器,可参考下方推荐列表,一般保留 1 - 2 个即可。AdGuard Home 除了可以作为广告过滤网关,如果设置了纯净 DNS 后,还可以避免运营商的 DNS 劫持
- BootStrap DNS 服务器地址:作为 DoH / DoT DNS 的前置 DNS 解析器,可参考下方推荐列表
- 查询方式、速度限制、EDNS、DNSSEC、拦截模式、DNS 缓存设置、访问设置可根据需要进行调整,一般保持默认设置即可
DNS 服务器推荐
不同地区连接至 DNS 服务器的速度各有差异,各位可以通过 Ping 测速的方式寻找当地连接延迟最低的 DNS 服务器。更多 DNS 服务器可以在 AdGuard 文档中找到。
DNS 提供商 | 类别 | 地址 |
---|---|---|
阿里 | IPv4 DNS | 223.5.5.5 |
IPv6 DNS | 2400:3200:baba::1 | |
DNS-over-Https | https://dns.alidns.com/dns-query | |
DNSPod | IPv4 DNS | 119.29.29.29 |
DNS-over-Https | https://doh.pub/dns-query | |
114 | IPv4 DNS | 114.114.114.114 |
IPv4 DNS | 8.8.8.8 | |
IPv6 DNS | 2001:4860:4860::8888 | |
DNS-over-Https | https://dns.google/dns-query | |
Cloudflare | IPv4 DNS | 1.1.1.1 |
IPv6 DNS | 2606:4700:4700::1111 | |
DNS-over-Https | https://dns.cloudflare.com/dns-query |
DNS 封锁清单
为了更好地发挥 AdGuard Home 去广告的功能,仅依靠默认的过滤规则是不够的,但也不宜过多,过多的过滤规则会影响解析的速度,各位可以根据需要添加过滤规则。
以浏览国内网站为主的用户可以使用 anti-AD + Halflife 过滤规则,如有浏览国外网站的需要,可以根据需要添加 AdGuard DNS Filter、Fanboy's Annoyances List 等规则。不同规则之间会存在重叠的情况,可以通过 AdGuard Home 的拦截日志分析哪些规则的使用频率最高,哪些规则拦截频率最低,再加以取舍。
过滤器
AdGuard Home 可以解析基础的 adblock 规则和 Hosts 语法。
系统自带过滤器
AdGuard Simplified Domain Names filter
https://adguardteam.github.io/AdGuardSDNSFilter/Filters/filter.txt
AdAway
hpHosts - Ad and Tracking servers only
https://hosts-file.net/ad_servers.txt
MalwareDomainList.com Hosts List
https://www.malwaredomainlist.com/hostslist/hosts.txt
自定义过滤器
neoHosts Full 127.0.0.1 兼容性更好
https://hosts.nfz.moe/127.0.0.1/full/hosts
Easylist 官方规则
https://easylist.to/easylist/easylist.txt
EasyList China 中文补充规则
https://easylist-downloads.adblockplus.org/easylistchina.txt
EasyList Lite 中文精简规则
https://raw.githubusercontent.com/cjx82630/cjxlist/master/cjxlist.txt
EasyPrivacy 隐私保护
https://easylist-downloads.adblockplus.org/easyprivacy.txt
CJX's Annoyance List 去自我推广列表
https://raw.githubusercontent.com/cjx82630/cjxlist/master/cjx-annoyance.txt
ChinaList 国内大部分视频网站的广告过滤 (广告净化器)
~【凉凉】http://tools.yiclear.com/ChinaList2.0.txt~
【备份】https://raw.githubusercontent.com/hopol/ChinaList2.0/master/ChinaList2.0.txt
乘风 广告过滤规则
https://raw.githubusercontent.com/xinggsf/Adblock-Plus-Rule/master/ABP-FX.txt
【码云更新】https://gitee.com/xinggsf/Adblock-Rule/raw/master/rule.txt
【MV规则】https://gitee.com/xinggsf/Adblock-Rule/raw/master/mv.txt
Fanboy+Easylist-Merged Ultimate List
https://fanboy.co.nz/r/fanboy-ultimate.txt
StevenBlack
http://sbc.io/hosts/alternates/fakenews-gambling-porn-social/hosts
yhosts
https://raw.githubusercontent.com/vokins/yhosts/master/hosts
大圣净化
https://raw.githubusercontent.com/jdlingyu/ad-wars/master/hosts
1024_hosts
https://raw.githubusercontent.com/Goooler/1024_hosts/master/hosts
neoHosts Full
https://hosts.nfz.moe/full/hosts
Google Host
https://raw.githubusercontent.com/googlehosts/hosts/master/hosts-files/hosts
ChinaList+EasyList(修正)
http://sub.adtchrome.com/adt-chinalist-easylist.txt
以下慎用
I don't care about cookies 屏蔽网站 cookies 相关警告!!!
https://www.i-dont-care-about-cookies.eu/abp/
如果你觉得过滤得还不够,也可以在“自定义过滤器规则”按照以下过滤规则自己编写:
||example.org^ – 拦截 example.org 域名及其所有子域名
@@||example.org^ – 放行 example.org 及其所有子域名
127.0.0.1 example.org – 将会把 example.org(但不包括它的子域名)解析到 127.0.0.1
! 注释符号,表示这是一行注释
这也是注释符号,同样表示这是一行注释
/REGEX/ – 正则表达式模式
具体请参考《官方说明》
https://kb.adguard.com/en/general/dns-filtering-syntax
附录
anti-AD
目前中文区命中率最高的广告过滤列表,精确的广告屏蔽和隐私保护。已支持AdGuardHome,dnsmasq,Surge,Pi-Hole,SmartDNS等。
Github地址:https://github.com/privacy-protection-tools/anti-AD**
https://gitee.com/privacy-protection-tools/anti-ad/raw/master/easylist.txt
halflife
合并EasylistChina、EasylistLite、CJX'sAnnoyance,以及补充的一些规则
Homepage: https://adf.minggo.eu.org
https://gitee.com/halflife/list/raw/master/ad.txt
yhosts tvbox
https://github.com/vokins/yhosts
里面有个TVBOX的规则
https://raw.githubusercontent.com/vokins/yhosts/master/data/tvbox.txt