Public IP or local IP? This guide shows where each one lives on every common system, and which one websites actually see.
Public IP versus local IP
There are two addresses worth knowing. The public IP address belongs to your whole connection and is what every website sees. The local IP address belongs to one device inside your network and is what your router uses to deliver traffic to that device.
Your device settings show the local address. The public address is shown by pages like this one, because it can only be observed from outside your network. A phone and a laptop on the same Wi-Fi share one public address and have different local ones.
Windows 10 and Windows 11
- Open Command Prompt or PowerShell and run ipconfig. The IPv4 Address line under your active adapter is your local address.
- For the same information in a window, open Settings, go to Network & internet, click Wi-Fi or Ethernet, then open the properties of the connected network. The IPv4 address and the gateway are listed there.
- To see the public address, open this site or any page that reports it. Windows does not display the public address anywhere in its own settings.
macOS
- Open System Settings, go to Network, click your Wi-Fi or Ethernet connection, then Details, then TCP/IP. The IP address shown there is the local one.
- In Terminal, ipconfig getifaddr en0 returns the Wi-Fi address on most Macs; on some models Ethernet is en1 instead, and a USB adapter usually gets a different interface name.
- A quick way to see the address without opening a window: hold Option and click the Wi-Fi menu bar icon.
- The public address is not shown in macOS settings; open this page to see it.
iPhone and iPad
- Open Settings, tap Wi-Fi, then tap the information button next to the network you are using.
- Scroll to the IP Address section. The address under IP Address is your local address on this network.
- The public address is not listed on iOS; open this page in Safari to see it.
Android
- Open Settings, go to Network & internet, then Internet or Wi-Fi, and tap the network you are connected to.
- Open the details for that network to see the IP address assigned to the phone.
- On some devices an overview is available under Settings, then About phone, then Status.
- The public address is shown by this site rather than by Android settings.
Linux
- Run ip addr to list every interface and its addresses. IPv4 addresses appear after inet, and IPv6 addresses after inet6.
- hostname -I prints the addresses of the current host in a compact form, which is convenient for scripting.
- To see which interface the system would use for internet traffic, run ip route get 1.1.1.1 — the reply names the source address and the device.
- The public address is not visible in local commands; open this page in a browser to see it.
Chromebook
- Open Settings, then Network, and select the Wi-Fi or Ethernet network you are using.
- The network details show the IP address assigned to the Chromebook.
- With the Linux development environment enabled, the commands ip addr and hostname -I also work in the terminal.
- Open this site to see the public address used by the whole connection.
Router and internet connection
The router is the device that holds the public address for your network. Its administration page is normally reached at an address such as 192.168.0.1, 192.168.1.1 or 10.0.0.1, and the exact address is often printed on a label on the router.
- Sign in to the router administration page.
- Open the status, internet or WAN page. Many routers show the public IPv4 address there, along with the gateway provided by the operator.
- If the WAN address is private, falls inside the 100.64.0.0/10 shared range, or differs from the address shown on this page, the connection is probably behind carrier-grade NAT or another router. In that case the address on the status page is not the one the internet sees.
Frequently asked questions
Why do my phone and computer show different IP addresses?
On the same Wi-Fi they share one public address, because the router translates both connections, but each device has its own local address inside the network. If the phone is on mobile data instead, it uses a completely different public address from the carrier.
Which IP address do websites actually see?
They see the public address of your connection, not the local address of your device. If you are behind CGNAT, the address websites see is held by your provider and may be shared with other customers.
How do I find my router's address?
The default gateway listed by ipconfig on Windows, by the TCP/IP details on macOS, or in the network details on Android is the router's local address. You can also try the addresses printed on the router label, such as 192.168.0.1 or 192.168.1.1.
When does my IP address change?
Mobile data and public Wi-Fi networks change addresses often. Home connections can keep the same address for days or weeks and change it after a router restart, an outage or a provider reconfiguration. Each VPN server you connect to also gives you a different public address.
Is my local IP address secret?
No. It is private in the sense that it is not routed on the internet, but every device on your network can see it, and any site you visit through a misconfigured setup could learn it. A local address cannot be used to reach your device from outside unless your router explicitly forwards a port to it.