How to find local/public IP address in Ubuntu 20.04

This is a step-by-step beginner’s guide that shows how to use the Ubuntu 20.04 graphical interface or Linux commands to verify local and public IPs on both IP4 and IPv6.

1. Find the IP address from the system settings.

On the default Gnome desktop, you can find the IP address of your wireless network in the following ways:

  • Open Settings and go to Wi-Fi in the left pane.
  • Click the gear icon after your connected Wi-Fi network.
  • The pop-up will display detailed information including the IP address.

How to find local/public IP address in Ubuntu 20.04

To find the IP address of your wired network, do the following:

  • Open Settings and go to Networks in the left pane.
  • Click the gear icon below the connected wired network.
  • The pop-up will display detailed information including the IP address.

How to find local/public IP address in Ubuntu 20.04

2. Check the local IP address with the ifconfig command.

Wired network names are usually eth0, eth1, eno1, but wireless network names are usually wlan0, wlan1, wlo1….

For other desktops or Ubuntu servers without a UI, you can do the following: ifconfig A command to find your IP.

ifconfig

If the command does not finish, run the command to install. sudo apt install net-tools

How to find local/public IP address in Ubuntu 20.04

3. Confirm the local IP address with the ip command.

Here’s another command that looks easier. Just run:

ip address

How to find local/public IP address in Ubuntu 20.04

4. Check the public IP address.

You can search public IPs via Google or other web search engines. If you don’t have a web browser, or if you’re using an Ubuntu server, you can find the public IP with the following command.

ifconfig If you are not behind a router, you will be notified of your public IP.

Alternatively, you can run the command at the console.

curl https://ipinfo.io/ip

How to find local/public IP address in Ubuntu 20.04

It’s a sequel.

It’s a sequel.
It’s a sequel.

It’s a sequel.
It’s a sequel.

Sidebar