Open Command Prompt and run a single command to see your IP address
The fastest way to find your IP address is to open Command Prompt and type ipconfig, then press Enter. Windows will display your IP address along with other network details in seconds. This works on any Windows computer without needing to install anything or navigate through menus.
Command Prompt is a built-in Windows tool that lets you type commands directly to your operating system. It is the quickest route to network information because it shows you exactly what your computer knows about its connection, without any translation or filtering by a graphical interface.
Key Takeaways
- Type ipconfig in Command Prompt to see your local IP address (the one your router assigned) and your network details.
- Type ipconfig /all to see additional information like your MAC address, DNS servers, and DHCP lease details.
- Your local IP address (usually starting with 192.168 or 10.0) is different from your public IP address, which is what websites see.
- To find your public IP address, type curl ifconfig.me in Command Prompt on Windows 10 or later, or visit a website like whatismyipaddress.com.
How to open Command Prompt on your Windows computer
Press the Windows key and type cmd. Click on "Command Prompt" when it appears in the search results. On Windows 11, you may see "Terminal" instead, which works the same way for this task.
Alternatively, right-click on the Start menu and select "Command Prompt" or "Windows Terminal" from the list. Either method opens the black window where you can type commands. You do not need administrator rights to run ipconfig, so you can use the regular version.
Understanding the information ipconfig shows you
When you type ipconfig and press Enter, you will see several sections, usually one for each network connection on your computer. Look for the section labeled "Ethernet" if you are plugged into a router with a cable, or "Wireless LAN adapter" if you are using Wi-Fi.
Within that section, you will see "IPv4 Address" — this is your local IP address, the one your router assigned to your computer. It typically looks like 192.168.1.100 or 10.0.0.50. You will also see "Default Gateway" (usually your router's address) and "Subnet Mask" (which defines your local network range).
If you have both Ethernet and Wi-Fi connected at the same time, you will see both sections. Your computer is using one or the other for internet traffic, depending on which connection is active. The one with an IPv4 Address listed is the one currently in use.
Getting more detailed network information with ipconfig /all
Type ipconfig /all and press Enter to see everything your computer knows about its network connection. This includes your MAC address (a unique identifier for your network card), your DNS servers (which translate website names into IP addresses), and your DHCP lease details (when your IP address expires and will be renewed).
The MAC address is useful if you need to set up port forwarding on your router or if your router uses MAC filtering to control which devices can connect. The DNS servers show which service is handling your web requests — usually your router's address, or sometimes your internet provider's servers.
Most people do not need this level of detail for everyday tasks, but it is helpful when troubleshooting network problems or setting up specific router features. Keep this information handy if you are working with your internet provider's support team or configuring advanced network settings.
Finding your public IP address instead of your local one
Your local IP address (the one ipconfig shows) is only visible to devices on your home network. Websites and online services see a different address — your public IP address — which your internet provider assigns to your router.
To find your public IP address from Command Prompt on Windows 10 or later, type curl ifconfig.me and press Enter. This command sends a request to an external server that responds by telling you what IP address it sees you coming from. The result appears on the next line.
If that command does not work on your computer, the simplest alternative is to visit a website like whatismyipaddress.com or myip.com in your web browser. These sites display your public IP address instantly. You do not need Command Prompt for this — it is just another way to get the same information.
Why you might need to know your IP address
Your local IP address is useful when you need to access your router's settings, set up port forwarding for gaming or remote access, or troubleshoot why a device is not connecting to your network. Some printers and smart home devices require you to know your computer's local IP address to communicate with them.
Your public IP address matters if you are setting up remote access to your computer, troubleshooting why a website is blocking you, or checking whether your internet provider has changed your address. It also helps you understand what information websites can see about your location and internet connection.
Neither address is sensitive information in the way a password is — your local IP is only useful to someone already on your network, and your public IP is visible to every website you visit. Knowing how to find both helps you understand your network setup and solve connection problems more quickly.
Troubleshooting if ipconfig does not show an IP address
If you run ipconfig and see "Media Disconnected" or no IPv4 Address listed, your computer is not currently connected to the network. Check that your Ethernet cable is plugged in or that you are connected to your Wi-Fi network. Then run ipconfig again.
If you are connected but still see no IP address, your router may not have assigned one yet. Wait 30 seconds and run ipconfig again. If the problem continues, restart your router by unplugging it for 10 seconds, plugging it back in, and waiting for it to fully restart (usually 2 to 3 minutes).
If you need to release and renew your IP address manually, type ipconfig /release followed by ipconfig /renew in Command Prompt. This forces your computer to ask the router for a new address. Wait a few seconds between the two commands.
Frequently Asked Questions
What is the difference between my local IP and public IP?
Your local IP is assigned by your router and only works on your home network. Your public IP is assigned by your internet provider and is what websites see when you visit them. Local IPs usually start with 192.168 or 10.0, while public IPs can be any address.
Can I change my IP address from Command Prompt?
You can release and renew your local IP using ipconfig /release and ipconfig /renew, which may give you a different address if your router allows it. You cannot directly change your public IP from Command Prompt — that is controlled by your internet provider, though restarting your router sometimes changes it.
Is it safe to share my IP address?
Sharing your public IP address is generally safe — websites already see it. Sharing your local IP is only risky if someone is already on your network. Never share your full network details (like your router password or MAC address) with people you do not trust.
Why does my IP address keep changing?
Most home routers assign IP addresses temporarily using DHCP, which means your local IP can change when you restart your computer or router. Your public IP can change when your router restarts or after a set period. If you need a stable address, you can set a static IP in your router settings.
Do I need administrator rights to run ipconfig?
No. The basic ipconfig command works with a regular user account. Some advanced commands like ipconfig /release may require administrator rights on some Windows versions, but you will get an error message if that is the case.