Updating Dynamic DNS (DDNS) With Wget on Linux

Wget is a program that retrieves content from web servers, and is part of the GNU Project. Its name is derived from World Wide Web and get. It supports downloading via HTTP, HTTPS, and FTP protocols. It also can be used for updating DDNS with wget.

It is available on almost all Linux distribution, so the Linux powered devices can update Dynamic DNS automatically (DDNS) with Wget. The DDNS currently available on script listed: OpenDNS, DynDNS, No-IP, DuckDNS, SystemNS, and DNS-O-Matic
It can also be used on almost all linux distribution (e.g. Arch, Debian, Ubuntu, OpenWrt, and more..) with Wget installed on the system

The steps

Step 1: Edit your crontab file, type the following command at the Linux shell prompt:
crontab -e
Step 2: Add the scripts to below of the cron


Write the format with this examples and paste the script at "script"
0 */1 * * * wget -qO- "$@" script
  • OpenDNS through DNS-O-Matic
    https://your@mail.com:password@updates.dnsomatic.com/nic/update > /dev/null 2>&1
  • DynDNS
    https://username:password@members.dyndns.org/nic/update?hostname=domain&myip=ip > /dev/null 2>&1
  • No-IP
    https://your@yours@mail.com:password@dynupdate.no-ip.com/nic/update?hostname=hostname.no-ip.biz > /dev/null 2>&1
  • DuckDNS (Update Single Domain)
    https://duckdns.org/update/[domain]/[api-key] > /dev/null 2>&1
  • DuckDNS (Update Multiple Domain)
    https://duckdns.org/update/domain1,domain2/9gx4cd1-11b9-0507-1qca-bB9742CgGY1d > /dev/null 2>&1
  • DuckDNS (Update Domain with specified IP)
    https://duckdns.org/update/domain1/9gx4cd1-11b9-0507-1qca-bB9742CgGY1d/ > /dev/null 2>&1
  • SytemNS
    https://system-ns.com/api?type=dynamic&domain=[DOMAIN]&command=set&token=[PASSWORD]&ip=[IP] > /dev/null 2>&1
  • DNS-O-Matic
    https://your@yours@mail.com:password@updates.dnsomatic.com/nic/update > /dev/null 2>&1


  • Adding  > /dev/null 2>&1 at the end of the script is important because all output will be shoved into a black hole to avoid problems
  • To configure the cron timing you can visit this site Cron Set-Up Timing
  • If the scripts is doesn't work make sure the id, password, token, and domain is correct
  • If you get error "wget: not an http or ftp url: https" or "wget: can't execute 'openssl': No such file or directory" that's mean you need to change https to http or update your wget to latest version and install openssl


  1. DDNS Client - OpenWrt Wiki
  2. List of Linux distributions
  3. DuckDNS Community
  4. Image by Blek
  5. Thanks to Grumpy Dad for adding additional DuckDNS and noticed HTTPS Support