Skip to content

Elastic IP

What is elastic IP?

  • An Elastic IP address is a static and public IPv4 address designed for dynamic cloud computing.

  • An Elastic IP address is associated with your AWS account.

  • With an Elastic IP address, you can mask the failure of an instance or software by rapidly remapping the address to another instance in your account.

An Elastic IP address is a reserved public IP address that you can assign to any EC2 instance in a particular region until you choose to release it. 

Reuse not allowed after release

When you associate an Elastic IP address with an instance or its primary network interface, the instance's public IPv4 address (if it had one) is released back into Amazon's pool of public IPv4 addresses. You cannot reuse a public IPv4 address, and you cannot convert a public IPv4 address to an Elastic IP address.

Elastic IP Overview

When you associate an Elastic IP address with an instance that previously had a public IPv4 address, the public DNS hostname of the instance changes to match the Elastic IP address.

To use an elastic IP, you must:

  • Allocate it for use in a VPC.
  • Associate it with an instance in that VPC.

Quota

  • By default, all AWS accounts are limited to 5 Elastic IP addresses per Region, because public (IPv4) internet addresses are a scarce public resource.

EIP basics 🌐

The following are the basic characteristics of an Elastic IP address:

  • An Elastic IP address is static; it does not change over time.

  • An Elastic IP address is for use in a specific Region only, and cannot be moved to a different Region

  • An Elastic IP address comes from Amazon's pool of IPv4 addresses, or from a custom IPv4 address pool that you have brought to your AWS account. We do not support Elastic IP addresses for IPv6

  • To use an Elastic IP address, you first allocate one to your account, and then associate it with your instance or a network interface

  • When you associate an Elastic IP address with an instance, it is also associated with the instance's primary network interface. When you associate an Elastic IP address with a network interface that is attached to an instance, it is also associated with the instance.

Associate Elastic IP

  • When you associate an Elastic IP address with an instance or its primary network interface, if the instance already has a public IPv4 address associated with it, that public IPv4 address is released back into Amazon's pool of public IPv4 addresses and the Elastic IP address is associated with the instance instead. You cannot reuse the public IPv4 address previously associated with the instance and you cannot convert that public IPv4 address to an Elastic IP address.

  • You can disassociate an Elastic IP address from a resource, and then associate it with a different resource. To avoid unexpected behavior, ensure that all active connections to the resource named in the existing association are closed before you make the change. After you have associated your Elastic IP address to a different resource, you can reopen your connections to the newly associated resource

  • A disassociated *Elastic IP address* remains allocated to your account until you explicitly release it. You are charged for all *Elastic IP address*es in your account, regardless of whether they are associated or disassociated with an instance.

  • When you associate an Elastic IP address with an instance that previously had a public IPv4 address, the public DNS host name of the instance changes to match the Elastic IP address

  • We resolve a public DNS host name to the public IPv4 address or the Elastic IP address of the instance outside the network of the instance, and to the private IPv4 address of the instance from within the network of the instance

  • When you allocate an Elastic IP address from an IP address pool that you have brought to your AWS account, it does not count toward your Elastic IP address limits.

  • When you allocate the *Elastic IP address*es, you can associate the *Elastic IP address*es with a network border group. This is the location from which we advertise the CIDR block. Setting the network border group limits the CIDR block to this group. If you do not specify the network border group, we set the border group containing all of the Availability Zones in the Region (for example, us-west-2)

  • An Elastic IP address is for use in a specific network border group only.


Was this page helpful?
-->