DDNS Dynamic Resolution

Use Adguard Private for convenient DDNS dynamic resolution service

What is DDNS?

DDNS (Dynamic DNS) allows you to bind a fixed domain name to a dynamic IP address, suitable for home broadband users to access internal network devices such as NAS, smart home controllers, etc.

Features

  • Easy to Use: Only one script is needed for automatic updates
  • No Additional Cost: No need to purchase a domain name
  • High Reliability: Relies on Adguard Private’s DNS infrastructure
  • Quick Effect: DNS records take effect immediately after update, no need to wait for DNS propagation

Preparation for Use

To use the DDNS feature, you need:

  1. A valid Adguard Private service
  2. Username and password for the management panel
  3. The domain name to be resolved (e.g., nas.home)

DDNS script download:

Configuration Steps

1. Gather Necessary Information

You need to prepare:

  1. Adguard Private service address, like: https://xxxxxxxx.adguardprivate.com
  2. Administrator username and password
  3. The domain name to be resolved, like: nas.home

2. Deploy the Update Script

The following script will automatically update the resolution address of the specified domain.

Windows PowerShell

# Download the script
Invoke-WebRequest -Uri https://www.adguardprivate.com/docs/startup/private/tutorial/ddns/update_dns.ps1 -OutFile update_dns.ps1
# Set execution policy (optional, only for the current session)
Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope Process
# Execute the script
.\update_dns.ps1 https://xxxxxxxx.adguardprivate.com admin:password123 nas.home

Linux && MacOS

# Download the script
wget https://www.adguardprivate.com/docs/startup/private/tutorial/ddns/update_dns.sh -O update_dns.sh
# Add execution permission
chmod +x update_dns.sh
# Execute the script
./update_dns.sh https://xxxxxxxx.adguardprivate.com admin:password123 nas.home

Frequently Asked Questions

How to Verify if it’s Effective?

You can check if the resolution correctly points to your current IP address using the ping your-domain.name command.

Or log into the service backend and check the Filter -> DNS Rewrite records.

How to Set Up Scheduled Updates?

Windows Scheduled Task

  1. Open Task Scheduler
  2. Create a basic task
  3. Set the run frequency (recommended 15-30 minutes)
  4. Choose PowerShell as the program location, and enter the full command of the script as the argument

Linux Cron Task

Add the following to crontab (execute every 15 minutes):

*/15 * * * * /path/to/update_dns.sh https://xxxxxxxx.adguardprivate.com admin:password123 nas.home

Precautions

  • Please keep your username and password safe to avoid leaks
  • It is recommended to add the update script to the system’s scheduled tasks for automatic execution
  • If the resolution does not take effect promptly, please check the network connection and the validity of the credentials