---
title: How to Configure Multiple Public IPv4 Addresses on a Vultr Compute Instance
url: https://docs.vultr.com/how-to-configure-multiple-public-ipv4-addresses-on-a-vultr-compute-instance
description: Learn how to set up and configure multiple public IPv4 addresses on your Vultr Compute Instance with our step-by-step guide for optimal network management.
publish_date: 2025-11-06T14:37:56.494000Z
last_updated: 2026-11-16T18:08:19.512361Z
author: Aashish Chaurasiya
header_image: https://docs.vultr.com/public/doc-assets/2360/5c47d90d-0180-411d-bc66-9737fe099c27.png
---

> Index of every Vultr Docs page in markdown: https://docs.vultr.com/llms.txt

Assigning multiple public IP addresses to a Vultr Cloud Compute instance allows you to host multiple services, bind applications to separate IPs, or configure advanced networking setups such as NAT or IP-based virtual hosts. You add IPv4 addresses in the Vultr Console and then configure them in the instance's operating system.

This guide explains how to assign and configure multiple public IPv4 addresses on a Vultr Cloud Compute instance. It covers adding IPv4 addresses in the Vultr Console, configuring them on Ubuntu, CentOS, FreeBSD, and Windows, and verifying that each address is active.

## Prerequisites

Before you begin, you need to:

* Have access to the [Vultr Console](https://console.vultr.com/).
* Have a [Vultr Cloud Compute instance](https://docs.vultr.com/products/compute/instances/cloud-compute/provisioning) running Ubuntu, CentOS, FreeBSD, or Windows.
* Have SSH access to the instance, or Remote Desktop access for Windows.

???+ note "Configure Multiple IPv4 Addresses on Ubuntu"

    Follow these steps to assign and configure multiple public IPv4 addresses on your Ubuntu instance.

    1. Log in to the [Vultr Console](https://console.vultr.com/).
    1. Click **Compute** in the left navigation menu, then click **Instances**.
    1. Click your Ubuntu instance to open its details page.
    1. Click the **Settings** tab, then click **IPv4**. The **Public Network** table lists the main IP address, netmask, and gateway assigned to the server.
    1. Under **Additional IPv4 IP**, click **Add Another IPv4 Address**.
    1. Check **Yes, add and restart this server**, then click **Add IPv4 Address** to assign a new IPv4 address to your server.
    1. Click the **networking configuration** link under **Public Network** to view the configuration examples for your OS. Ubuntu requires you to configure the new IP address manually. The following is an example Netplan configuration for Ubuntu.

        ```yaml
        network:
          version: 2
          renderer: networkd
          ethernets:
            enp1s0:
              dhcp4: no
              addresses: [192.0.0.4/23,192.0.2.5/32]
              nameservers:
                addresses: [192.0.0.6]
              routes:
              - to: default
                via: 192.0.0.1
              - to: 169.254.0.0/16
                via: 192.0.0.1
                metric: 100
        ```

        Replace the following values with those provided in your Vultr Console:

        * `192.0.0.4/23`: Your main IP address and prefix length.
        * `192.0.2.5`: Your newly assigned IPv4 address.
        * `192.0.0.6`: Your DNS server.
        * `192.0.0.1`: Your gateway IP.

        In the above configuration:

        * `network`: The top-level key that begins the Netplan configuration.
        * `version`: Specifies the Netplan format version. Version 2 is the standard used in most modern Ubuntu systems.
        * `renderer`: Indicates which backend to use for applying the configuration.
        * `ethernets`: Defines Ethernet interface configurations. All Ethernet-based interfaces are declared under this section.
        * `enp1s0`: The name of the network interface to configure.
        * `dhcp4: no`: Disables DHCP for IPv4, so the interface uses a static IP configuration.
        * `addresses`: A list of static IP addresses assigned to the interface.
        * `nameservers`: Specifies DNS resolver addresses.
        * `routes`: Adds static routes to control traffic flow.
        * `to: default / via: 192.0.0.1`: Sets the default gateway to 192.0.0.1, used for routing external traffic.
        * `to: 169.254.0.0/16 / via: 192.0.0.1 / metric: 100`: Routes link-local addresses via the same gateway with a metric of 100.

    1. After you have copied the configuration, SSH into your Ubuntu server.
    1. Create a new Netplan configuration file using a text editor such as `nano`.

        ```console
        $ sudo nano /etc/netplan/10-enp1s0.yaml
        ```

    1. Paste the copied configuration into the file, then save and exit.
    1. Set restrictive file permissions to prevent unauthorized changes.

        ```console
        $ sudo chmod 400 /etc/netplan/10-enp1s0.yaml
        ```

    1. Test the configuration before applying it permanently.

        ```console
        $ sudo netplan try
        ```

        This command applies the new network configuration temporarily and gives you 120 seconds to confirm that everything is working as expected. If the system loses connectivity or something goes wrong, Netplan automatically rolls back to the previous configuration after the timeout, preventing accidental lockouts on remote systems.

        * Press :key_enter: to accept and apply the changes permanently.
        * Press :key_esc: or wait for the timer to expire if something breaks.

    1. If everything works as expected, apply the configuration permanently.

        ```console
        $ sudo netplan apply
        ```

    1. Restart the server from the **Vultr Console** by clicking the **Server Restart** icon to make the changes take effect.
    1. After the server restarts, SSH into the server and list the IPv4 addresses on the network interface.

        ```console
        $ ip -4 addr show enp1s0
        ```

        Verify that the output lists both the main IP address and the newly assigned IPv4 address.

??? note "Configure Multiple IPv4 Addresses on CentOS"

    Follow these steps to assign and configure multiple public IPv4 addresses on your CentOS instance.

    1. Log in to the [Vultr Console](https://console.vultr.com/).
    1. Click **Compute** in the left navigation menu, then click **Instances**.
    1. Click your CentOS instance to open its details page.
    1. Click the **Settings** tab, then click **IPv4**. The **Public Network** table lists the main IP address, netmask, and gateway assigned to the server.
    1. Under **Additional IPv4 IP**, click **Add Another IPv4 Address**.
    1. Check **Yes, add and restart this server**, then click **Add IPv4 Address** to assign a new IPv4 address to your server.
    1. Restart the server from the **Vultr Console** by clicking the **Server Restart** icon to make the changes take effect.

        On boot, **cloud-init** automatically configures the newly assigned IP address in the network interface.

    1. After the server restarts, SSH into the server and list the IPv4 addresses on the instance.

        ```console
        $ ip -4 addr show
        ```

        Verify that the output lists both the main IP address and the newly assigned IPv4 address.

    > [!NOTE]
    > If the new IP address is not automatically configured, click the **networking configuration** link under **Public Network** in the Vultr Console and follow the manual steps provided for your operating system.

??? note "Configure Multiple IPv4 Addresses on FreeBSD"

    Follow these steps to assign and configure multiple public IPv4 addresses on your FreeBSD instance.

    1. Log in to the [Vultr Console](https://console.vultr.com/).
    1. Click **Compute** in the left navigation menu, then click **Instances**.
    1. Click your FreeBSD instance to open its details page.
    1. Click the **Settings** tab, then click **IPv4**. The **Public Network** table lists the main IP address, netmask, and gateway assigned to the server.
    1. Under **Additional IPv4 IP**, click **Add Another IPv4 Address**.
    1. Check **Yes, add and restart this server**, then click **Add IPv4 Address** to assign a new IPv4 address to your server.
    1. SSH into the server as `root`.
    1. Create a backup of the existing `/etc/rc.conf` file.

        ```console
        # cp -pv /etc/rc.conf /etc/rc.conf.backup
        ```

    1. Open the `/etc/rc.conf` file in a text editor.

        ```console
        # vi /etc/rc.conf
        ```

    1. Update the file with the following network configuration.

        ```ini
        hostname="FreeBSD"
        sshd_enable="YES"
        ntpd_enable="YES"
        static_routes="linklocal"
        route_linklocal="-net 169.254.0.0/16 -interface vtnet0"
        ifconfig_vtnet0="inet 192.0.0.4 netmask 255.255.254.0"
        defaultrouter="192.0.0.1"
        ifconfig_vtnet0_alias0="192.0.2.5 netmask 255.255.255.255"
        ```

        Replace the existing `ifconfig_vtnet0` line so that the file contains only one `ifconfig_vtnet0` entry, then save and close the file. Replace the following values with those provided in your Vultr Console:

        * `192.0.0.4`: Your main IP address.
        * `192.0.2.5`: Your newly assigned IPv4 address.
        * `192.0.0.1`: Your gateway IP.

        In the above configuration:

        * `ifconfig_vtnet0`: Sets your primary IP.
        * `defaultrouter`: Defines the system’s default gateway.
        * `ifconfig_vtnet0_alias0`: Adds an alias for the additional public IP using a `/32` netmask.

        > [!NOTE]
        > If your system uses a different network interface (such as `xn0`, `em0`, or `re0`), replace `vtnet0` accordingly. Use `ifconfig` to identify your active interface.

    1. Restart the server from the **Vultr Console** by clicking the **Server Restart** icon to make the changes take effect.
    1. After the server restarts, SSH into the server and list the IPv4 addresses on the network interface.

        ```console
        # ifconfig vtnet0 inet
        ```

        Verify that the output lists both the main IP address and the newly assigned IPv4 address.

??? note "Configure Multiple IPv4 Addresses on Windows"

    Follow these steps to assign and configure multiple public IPv4 addresses on your Windows instance.

    ### Add an IPv4 Address in the Vultr Console

    1. Log in to the [Vultr Console](https://console.vultr.com/).
    1. Click **Compute** in the left navigation menu, then click **Instances**.
    1. Click your Windows instance to open its details page.
    1. Click the **Settings** tab, then click **IPv4**. The **Public Network** table lists the main IP address, netmask, and gateway assigned to the server.
    1. Under **Additional IPv4 IP**, click **Add Another IPv4 Address**.
    1. Check **Yes, add and restart this server**, then click **Add IPv4 Address** to assign a new IPv4 address to your server.
    1. After the IP is assigned, connect to the server using Remote Desktop and configure it in Windows.

    ### Configure the Main IPv4 Address

    Switch the network adapter from DHCP to a static configuration for the main IPv4 address before you add more addresses.

    1. Open **Control Panel** from the **Start** menu.
    1. Click **Network and Internet**, then click **Network and Sharing Center**.
    1. Click **Change adapter settings**.
    1. Right-click the primary Ethernet adapter, then click **Properties**. The **Ethernet Properties** window opens.
    1. Select **Internet Protocol Version 4 (TCP/IPv4)**, then click the **Properties** button. The **Internet Protocol Version 4 (TCP/IPv4) Properties** window opens.
    1. Select **Use the following IP address** and populate the fields:

        * **IP address**: 192.0.0.4
        * **Subnet mask**: 255.255.254.0
        * **Default gateway**: 192.0.0.1

        Replace the above values with your main IP address, netmask, and gateway listed in the Vultr Console.

    1. Select **Use the following DNS server addresses** and populate the fields:

        * **Preferred DNS server**: 192.0.0.6
        * **Alternate DNS server**: Leave blank.

    1. Click **OK**, then click **OK** again on the **Ethernet Properties** window to apply the static configuration.

        > [!NOTE]
        > It's normal for the network connection to temporarily drop after saving the changes.

    ### Add Additional IPv4 Addresses

    After the primary IPv4 address is manually configured, follow these steps to add more public IP addresses.

    1. Repeat the steps in the previous section to open the **Internet Protocol Version 4 (TCP/IPv4) Properties** window for the same network adapter.
    1. Click the **Advanced** button.
    1. Under the **IP addresses** section, click **Add** to add another IP address.
    1. Enter your additional IP address:

        * **IP address**: 192.0.2.5
        * **Subnet mask**: 255.255.255.255

    1. Click **OK** on all open windows to apply the changes.
    1. Restart the server from the **Vultr Console** by clicking the **Server Restart** icon to make the changes take effect.
    1. After the server restarts, connect using Remote Desktop, open PowerShell, and list the IP configuration.

        ```pwsh
        > ipconfig
        ```

        Verify that the output lists both the main IP address and the newly assigned IPv4 address. The output resembles the following:

        ```
        Windows IP Configuration

        Ethernet adapter Ethernet Instance 0:

           Connection-specific DNS Suffix  . :
           Link-local IPv6 Address . . . . . : fe80::5400:5ff:fe8b:4d04%3
           IPv4 Address. . . . . . . . . . . : 192.0.2.5
           Subnet Mask . . . . . . . . . . . : 255.255.255.255
           IPv4 Address. . . . . . . . . . . : 192.0.0.4
           Subnet Mask . . . . . . . . . . . : 255.255.254.0
           Default Gateway . . . . . . . . . : 192.0.0.1
        ```

## Conclusion

You have assigned additional public IPv4 addresses to a Vultr Cloud Compute instance in the Vultr Console and configured them in the operating system using Netplan on Ubuntu, cloud-init on CentOS, `rc.conf` on FreeBSD, and the network adapter settings on Windows. Each instance now responds on its main IP address and every additional IPv4 address you assigned.
