Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

View DNS hostnames for your EC2 instance

Focus mode
View DNS hostnames for your EC2 instance - Amazon Virtual Private Cloud

You can view the DNS hostnames for a running instance or a network interface using the Amazon EC2 console or the command line. Knowing these hostnames is important for connecting to your resources.

The Public DNS (IPv4) and Private DNS fields are available when the DNS options are enabled for the VPC that is associated with the instance. For more information, see DNS attributes for your VPC.

Instance

To view DNS hostnames for an instance using the console
  1. Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/.

  2. In the navigation pane, choose Instances.

  3. Select your instance from the list.

  4. In the details pane, the Public DNS (IPv4) and Private DNS fields display the DNS hostnames, if applicable.

To view DNS hostnames for an instance using the command line

Network interface

To view the private DNS hostname for a network interface using the console
  1. Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/.

  2. In the navigation pane, choose Network Interfaces.

  3. Select the network interface from the list.

  4. In the details pane, the Private DNS (IPv4) field displays the private DNS hostname.

To view DNS hostnames for a network interface using the command line
PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.