Skip to content

Private vs Public vs Elastic IPΒΆ

Public IP

Private IP

Elastic IP

By default, your AWS EC2 machine comes with: - A private IP for internal AWS network - A public IP for the [[internet]]

When we are doing ssh into our AWS EC2 machines: - We can't use a private IP, because we are not in the same network - We can only use the public IP

If your machine is stopped and then started, the public IP can change

When viewing the EC2 instance, we can see these IP addresses:

You can also visit the Elastic IPs section and allocate new Elastic IP addresses.

Once it's created, we can associate it with an instance.