How Do I Use Duck DNS for Minecraft Server?


Larry Thompson

Are you looking for a way to use Duck DNS for your Minecraft server? Look no further!

In this tutorial, we will guide you through the process of setting up Duck DNS and connecting it to your Minecraft server. By the end of this article, you’ll be able to access your Minecraft server using a custom domain name.

What is Duck DNS?

Duck DNS is a free dynamic DNS service that allows you to assign a domain name to your home network’s public IP address. It provides an easy way to access devices on your network without having to remember the IP address each time.

Step 1: Sign Up for Duck DNS

To get started, visit the Duck DNS website at and sign up for an account. You’ll need to choose a subdomain name that will be used as part of your custom domain. For example, if you choose “myminecraftserver” as your subdomain, your custom domain will be

Step 2: Install the Duck DNS Updater

Once you have signed up for Duck DNS, you’ll need to install the Duck DNS updater on the machine where your Minecraft server is running. The updater will periodically check for changes in your public IP address and update the DNS records accordingly.

For Linux:

  1. Open a terminal window.
  2. Navigate to the location where you want to install the updater. For example, /opt/duckdns/.
  3. Create a new directory with the command: mkdir duckdns.
  4. Move into the newly created directory: cd duckdns.
  5. Download the updater script using the command: wget\?domains=your-subdomain&token=your-token&ip=$(wget -qO-
  6. Make the updater script executable with the command: chmod +x
  7. Edit the updater script using a text editor and replace “your-subdomain” with your actual subdomain and “your-token” with your token obtained from Duck DNS.
  8. Schedule the script to run every 5 minutes by adding an entry to your crontab file.

    Open your crontab file with the command: crontab -e. Add the following line to the file: * * * * * /opt/duckdns/ >/dev/null 2>&1. Save and exit the text editor.

For Windows:

  1. Download and install Python from the official website ( if you haven’t already.
  2. Create a new directory in a location of your choice, e.g., “C:\duckdns”.
  3. In that directory, create a new Python script file named “” using a text editor.
  4. Add the following code to “”:
    import requests
    import time

    url = '' + requests.get('').text

    while True:
    response = requests.get(url)
  5. Replace “your-subdomain” with your actual subdomain and “your-token” with your token obtained from Duck DNS.
  6. Save the file and exit the text editor.
  7. To run the updater script, open a command prompt, navigate to the directory where you saved “”, and run the command: python
  8. You can also create a shortcut to the script and place it in your Startup folder to ensure it runs automatically on system startup.

Step 3: Configure Port Forwarding

In order for your Minecraft server to be accessible from outside your home network, you’ll need to configure port forwarding on your router to forward incoming connections on port 25565 (default Minecraft server port) to the internal IP address of your Minecraft server. Consult your router’s documentation or visit for detailed instructions on how to set up port forwarding for your specific router model.

Step 4: Test Your Setup

To test if Duck DNS is working correctly, simply open a web browser and enter your custom domain name, e., myminecraftserver. If everything is set up correctly, you should see the Duck DNS landing page or be redirected to your Minecraft server.

That’s it! You now know how to use Duck DNS for your Minecraft server.

With a custom domain, accessing your server will be much easier and more convenient. Enjoy playing Minecraft with your friends!

Note: It’s important to keep in mind that Duck DNS relies on your public IP address, which may change periodically depending on your internet service provider. The updater script will automatically update the DNS records whenever your IP address changes.