How to find your IP address in Command Prompt

Open Command Prompt on your computer and type ipconfig, then press Enter. The tool will display a list of all network connections on your device. Look for the line that says IPv4 Address — that is your local IP address, the one your router assigned to this specific device. It usually starts with 192.168 or 10.0.

If you want to see only the essential information without extra details, type ipconfig /all instead. This shows your IPv4 address, your MAC address (a unique identifier for your device's network card), and your default gateway (usually your router's address). All three appear in the same output, which can be useful if you need to troubleshoot network problems or set up port forwarding.

The address Command Prompt shows you is not the address the outside internet sees. That is your public IP address, which is different and belongs to your internet service provider. Command Prompt shows only your local network address — the one that matters for connecting to devices inside your home.

Key Takeaways

  • Type ipconfig in Command Prompt to see your local IP address under the IPv4 Address line.
  • Your local IP address (usually 192.168.x.x or 10.0.x.x) is assigned by your router and only works on your home network.
  • Use ipconfig /all to see additional details like your MAC address and default gateway if you need them for network setup.
  • The address shown in Command Prompt is different from your public IP address, which is what websites see when you browse.

Why you might need to check your IP address

You need your local IP address when you want to log into your router's settings, set up a printer on your network, or troubleshoot why a device cannot connect to another device at home. If a family member's phone cannot print to your wireless printer, for example, you may need to check both devices' IP addresses to confirm they are on the same network.

You also need it if you are setting up port forwarding — a way to let outside traffic reach a specific device on your network. Your router's control panel asks for the local IP address of the device you want to expose, and Command Prompt is the fastest way to find it.

Understanding what ipconfig shows you

When you run ipconfig, you see a section for each network connection your computer has. Most home computers have at least two: Ethernet (wired) and Wireless LAN (Wi-Fi). If you are connected by Wi-Fi, look at the Wireless LAN section. If you are plugged in with a cable, look at Ethernet.

The IPv4 Address line is what you are looking for. Below it, you will see the Subnet Mask (usually 255.255.255.0), which tells your device which other addresses are on the same local network. You do not need to memorize this, but it is useful to know it exists if someone asks you about your network setup.

The Default Gateway is your router's address — the device that connects your home network to the internet. If you need to change your Wi-Fi password or port forwarding rules, you type this address into your web browser to reach your router's control panel.

Checking your IP address on different Windows versions

Command Prompt works the same way on Windows 10, Windows 11, and earlier versions. Open the Start menu, type cmd, and press Enter. On Windows 11, you can also right-click the Start button and select "Terminal" to open PowerShell, which accepts the same ipconfig command.

If you prefer not to use Command Prompt, you can also find your IP address through Settings. On Windows 10 and 11, go to Settings > Network & Internet > Wi-Fi (or Ethernet if wired), then click your network name. Scroll down to find "IPv4 address" in the details section. This method is slower but shows the same information.

What to do if ipconfig shows multiple addresses

If you see more than one IPv4 address, you likely have multiple network adapters or virtual networks running. The most common reason is virtualization software like Docker or VirtualBox, which creates fake network connections your computer uses internally. Ignore these unless you are specifically working with that software.

If you see an address that starts with 169.254, your device is not properly connected to the network. This is an automatic fallback address that appears when your router cannot assign a real address. Restart your router and your device, then run ipconfig again. The address should change to 192.168 or 10.0.

Saving or copying your IP address

If you need to write down your IP address or send it to someone, you can copy it directly from Command Prompt. Right-click on the window, select "Select All", then right-click again and choose "Copy". You can then paste it into an email or document.

For a cleaner output you can save to a file, type ipconfig > myip.txt and press Enter. This creates a text file called myip.txt in your user folder with all your network information. You can open it in Notepad and copy just the parts you need.

Frequently Asked Questions

Is my IP address private or can other people see it?

Your local IP address (the one Command Prompt shows) is private — only devices on your home network can see it. Your public IP address, which the internet sees, is visible to websites you visit, but it does not identify you personally. Your internet service provider knows which customer owns each public IP, but websites cannot look that up.

Why does my IP address change sometimes?

Your router assigns local IP addresses temporarily, usually for 24 hours or longer. When that time expires, your device gets a new one — often the same address, but not always. If you need the same address every time (for port forwarding or printer setup), you can assign a static IP in your router's settings, which locks that device to one address permanently.

Can I use ipconfig to find someone else's IP address on my network?

No. ipconfig shows only your own device's address. To see all devices connected to your network, you need to log into your router's control panel using the default gateway address. Most routers have a "Connected Devices" or "DHCP Clients" page that lists everything currently online.

What if Command Prompt says "ipconfig is not recognized"?

This usually means Command Prompt did not open with the right permissions. Close it and try again, but this time right-click the Command Prompt icon and select "Run as administrator". On some older systems, you may need to type the full path: C:\Windows\System32\ipconfig.

Is there a difference between ipconfig and ipconfig /all?

ipconfig shows the basics: your IP address, subnet mask, and default gateway. ipconfig /all adds your MAC address, DHCP server address, and DNS servers. You only need the extra information if you are troubleshooting network problems or setting up advanced features.