aws

Configure a static IP address

AWS instances are launched with a dynamic IP address by default, which means that the IP address changes every time the server is stopped and restarted. In many cases, this is not desired and so, users also have the option to assign the server a static IP address (also known as an “elastic IP”).

To configure a static IP address:

  • Log in to the AWS EC2 Dashboard.

  • If required, use the region selector in the top right corner to switch to the region where your instance was launched.

  • Select the instance in the dashboard.

  • In the left navigation bar, select the “Network & Security -> Elastic IPs” menu item.

  • Click the “Allocate New Address” button.

    AWS IP address configuration

  • Click “Allocate” in the next screen.

    AWS IP address configuration

    A new static IP address will be generated and will appear in the list of available IP addresses.

    AWS IP address configuration

Next:

  • From the “Actions” drop-down menu, select the “Associate Address” menu item.

    AWS IP address configuration

  • In the resulting dialog box, enter the instance ID of your server and click the “Associate” button.

    AWS IP address configuration

The elastic IP address will now be assigned to your server and will persist across shutdown/reboot operations.

Last modification July 26, 2023