An IP checker tells you which IP addressIP address The number address of a device on the internet, like 203.0.113.10. Computers use it to find each other, the way post uses street addresses. More about IP address → your device or network is using, so you can give it to support, add it to a firewall rule or check that a VPN is working. This guide shows how to check both your public and private IP address on Windows, macOS, Linux, iPhone and Android, how to check the IP address of a website or server, and how to read what an IP checker shows you.
Most devices have two addresses worth knowing. Your public IP address is the one the internet sees: open an IP checker website, or run curl -4 icanhazip.com in a terminal. Your private IP address is the one inside your home or office network: run ipconfig on Windows, ipconfig getifaddr en0 on a Mac, or ip -br addr on Linux, or look in your phone’s Wi-Fi settings. To check a website’s server address instead, run nslookup example.com.
Which IP address do you want to check?
Before you check anything, decide which address you are after. People are often surprised that the number on their laptop does not match the number an IP checker website shows. Both are correct: they are different addresses doing different jobs.
| Address | What it is | Example | Where to find it |
|---|---|---|---|
| Public | The address the rest of the internet sees for your connection | 203.0.113.10 | An IP checker website or curl |
| Private (local) | The address your router gave the device inside your network | 192.168.1.20 | Device network settings or ipconfig |
| Router (gateway) | The router’s own address inside your network | 192.168.1.1 | Listed next to the private address as the default gateway |
| IPv6 | The newer, longer address format, often public on every device | 2001:db8::20 | Both IP checker sites and device settings |
| A server’s address | Where a domain name points | 198.51.100.7 | nslookup or dig |
At home and in most offices, every device has its own private address and they all share one public address. The router translates between them, a process called NAT (network address translation). That is why your laptop shows 192.168.1.20 while a website sees 203.0.113.10. If you want the background on why addresses come in these types, read our explainer on what an IP address is, listed under Related below.
As a rough guide to which one you need:
- Allowing your office into a server firewallFirewall A gatekeeper that decides which connections are allowed into a server and blocks the rest. More about Firewall → or a hosting control panel: your public IP address.
- Connecting to a printer, NAS or Raspberry Pi on the same network: that device’s private IP address.
- Pointing a domain at a server: the server’s public IP address, which your host gives you.
- Checking a VPN is working: your public IP address, before and after connecting.
How to check your public IP address
Your public address belongs to your internet connection, not to one device, so any device on the same network will usually show the same answer.
Use an IP checker website
Open any IP checker website in a browser. It reads the address your request came from and shows it back to you, usually with a guessed location and the name of your internet provider. Search engines will also show it if you search for “what is my IP”.
If you see two addresses, one short and one long, the short one is your IPv4 address and the long one with colons is your IPv6 address. Many connections now have both.
Check it from a terminal
A terminal is quicker and gives you just the address, with no adverts. These commands ask a small web service which address your request came from.
On macOS and Linux:
curl -4 icanhazip.com
curl -6 icanhazip.com
On Windows 10 and 11, curl is built in, but in PowerShell you must type curl.exe because plain curl means something different there:
curl.exe -4 icanhazip.com
The -4 asks for your IPv4 address and -6 for your IPv6 address. If the -6 command fails or times out, your connection probably has no IPv6, which is normal.
You can also ask a DNSDNS The internet’s phone book. It turns a name people can remember, like example.com, into the number address computers use to find the server. More about DNS → server instead of a website. This works on any system that has dig or nslookup:
dig +short myip.opendns.com @resolver1.opendns.com
nslookup myip.opendns.com resolver1.opendns.com
Success looks like a single address such as 203.0.113.10. If you use the same commands on a VPSVPS A private slice of a powerful server, with its own guaranteed share of memory and processing and full control, at a fraction of the price of a whole machine. More about VPS → or cloud server over SSH, you get that server’s public address, which is handy for setting up DNS records.
How to check your private IP address
The private address is set per device, so check it on the device you care about.
Windows 10 and 11
- Press the Windows key, type
cmdand open Command Prompt (PowerShell works too). - Run
ipconfig. - Find the section for the connection you are using, such as “Wireless LAN adapter Wi-Fi” or “Ethernet adapter Ethernet”.
- Read the line IPv4 Address. The Default Gateway line just below it is your router.
Without a terminal, open Settings, then Network & internet, choose Wi-Fi or Ethernet, then open the properties of your connection and scroll to IPv4 address.
For more detail, ipconfig /all also shows the DNS servers your PC uses and its hardware (MAC) address.
macOS
In System Settings, choose Wi-Fi (or Network for a cable), click Details next to the network you are on, then open TCP/IP. The IP address and Router fields are what you want.
From Terminal:
ipconfig getifaddr en0
On most Macs en0 is the Wi-Fi connection. If the command prints nothing, try en1, or run ifconfig and look for the inet line under the active interface.
Linux
Run ip -br addr for a short list of every network interface and its addresses, or hostname -I for just the addresses. Our Linux IP address guide, linked under Related, walks through every option, including how to tell which address a server uses for outgoing traffic.
iPhone and iPad
Open Settings, tap Wi-Fi, then tap the round i button next to the network you are connected to. The IP Address is listed under IPv4 Address, along with the Router address.
Recent versions of iOS and Android use a “private Wi-Fi address” by default. That setting changes the hardware (MAC) address the phone shows each network, not its IP address, so the IP address you read here is still the right one to use.
Android
Menus differ between phone makers, but on most phones: open Settings, tap Network & internet (or Connections), tap Internet or Wi-Fi, then tap the gear or the name of the network you are on. The IP address is shown there, sometimes under Advanced or Network details.
Your phone’s private address is only meaningful while it is on Wi-Fi. On mobile data, the phone talks directly to the mobile network and an IP checker website is the only useful way to see your public address.
How to check the IP address of a website or server
Sometimes the question is not “what is my IP” but “which server does this domain point to”. Before and after you point a domain to a server, you can check the answer yourself.
On Windows, macOS or Linux:
nslookup example.com
On macOS and Linux, dig gives a cleaner answer:
dig +short example.com A
dig +short example.com AAAA
The A lookup returns the IPv4 address and the AAAA lookup returns the IPv6 address. If the site sits behind a CDNCDN A network of servers around the world that keep copies of your site’s files, so each visitor gets them from somewhere nearby. Faster pages, less work for your server. More about CDN → (content delivery network) or a proxy service, you will see the CDN’s addresses rather than your server’s own, which is expected. For reading every part of the reply and checking whether a DNS change is live yet, see how to run a DNS lookup.
To go the other way and find out who an address belongs to, use whois:
whois 203.0.113.10
The reply names the organisation the address range is registered to, usually an internet provider or hosting company, and gives an abuse contact. A reverse lookup with dig -x 203.0.113.10 +short shows the hostname set for the address, if there is one.
What an IP checker shows, and how accurate it is
Besides the address itself, most IP checker websites show extra details. Here is how far to trust each one.
| Detail | Where it comes from | How reliable |
|---|---|---|
| IP address | The connection your browser made | Exact |
| Internet provider | Public registration records for the address range | Usually right |
| Country | Geolocation databases | Usually right |
| City or region | Geolocation databases | Often wrong, may show your provider’s nearest hub |
| Hostname | A reverse DNS lookup | Exact, if one is set |
Location is a guess built from databases, not a reading of where you are. An IP address alone does not reveal your street address or name. Your internet provider knows which customer had an address at a given time, but a website does not.
If a VPN or proxy is switched on, an IP checker shows the VPN’s address and location instead of yours. That is how you check a VPN is working: compare the result with it switched off and on. To also confirm your DNS lookups go through the VPN, run a DNS leak test.
Why your IP address changes
Most home and mobile connections have a dynamic public IP address. Your provider can hand out a different one when your router restarts, after a set time, or when you switch between Wi-Fi and mobile data. Private addresses can also change, because the router gives them out for a limited time.
This matters if you use your IP address in a firewall allow-list, such as letting only your office reach a server’s SSHSSH A secure way to type commands on a server from your own computer, as if you were sitting at it. More about SSH → port. If the address changes, you are locked out until you update the rule. Options are:
- Ask your provider for a static public IP address, which many business plans include.
- Keep a second way in, such as your host’s web console, before you limit access by IP.
- On your own network, set a DHCP reservation in the router so a printer or server always gets the same private address.
If you are setting up allow-lists on a server, our guide on setting up a firewall on Linux shows how to do it without locking yourself out.
Common problems
| Symptom | Cause | Fix |
|---|---|---|
| The IP checker and ipconfig show different addresses | One is public, one is private, with NAT in between | Both are correct: use the one that matches your task |
| Address starts with 169.254 | The device did not get an address from the router | Restart Wi-Fi or the router, then check again |
| Router’s internet address starts with 100.64 to 100.127 | Your provider shares one public address among customers (carrier-grade NAT) | Incoming connections will not reach you: ask your provider for a public or static address |
| Public address keeps changing | Dynamic address from your provider | Ask for a static address, or avoid IP-only allow-lists |
| curl -6 times out | No IPv6 on your connection | Nothing to fix: use the IPv4 address |
| Website shows the wrong city | Geolocation databases are approximate | Ignore it: only the address itself is exact |
| Another device on the network shows a different public address | It is using a VPN or mobile data | Turn the VPN off or join the same Wi-Fi |
Official documentation
- ipconfig command reference from Microsoft.
- RFC 1918, which defines the private address ranges.
- RFC 6598, which defines the 100.64.0.0/10 range used for carrier-grade NAT.
Related
- What is an IP address? explains IPv4, IPv6, public and private addresses from the ground up.
- How to check your IP address in Linux goes deeper on every Linux command and option.
- DNS record types explained covers the A and AAAA recordsAAAA record The same as an A record, but for the newer, longer kind of internet address (IPv6). Only needed if your server has one. More about AAAA record → that hold a server’s address.
- Google DNS explains what 8.8.8.8 is and how to change the DNS server your device uses.
Something out of date? Software changes. If a step no longer works, tell us and we will check it and update the page.


