Published on

Assigning a Static IP with EC2 Elastic IP

Authors

When you restart an EC2 instance on AWS, its IP address may change. That is fine if you are only experimenting, but if you want to use your own domain, you need a fixed IP address. To keep the IP from changing on AWS, assign an Elastic IP.

In the left-hand navigation, choose Elastic IPs under NETWORK & SECURITY. There is a button labeled Allocate New Address at the top. Click it to obtain an IP address.

Then use Associate Address to attach that IP to your instance. One thing to note is that you are charged if you allocate an IP address but do not associate it with an instance.