Finding Your IP Address Using Command Prompt
Updated on November 19, 2025, by ITarian
If you’ve ever managed a network, troubleshooted a device, configured a firewall, or tried to understand what’s happening behind your internet connection, you’ve probably wondered how to check IP address in CMD quickly and accurately. Whether you’re an IT manager, a cybersecurity professional, or someone who just wants to understand your system better, knowing your IP address is essential for diagnosing issues and maintaining secure operations.
The Command Prompt (CMD) gives you one of the fastest and most reliable ways to view your IP address—both internal and external. And the best part? It works the same across almost all versions of Windows. In this article, we’ll walk through everything you need to know about checking your IP address using CMD, understanding what those numbers mean, and using additional network commands that every IT and business professional should know.
Let’s dive in—and make things simple.
Why Your IP Address Matters
Your IP address is the identity of your device on a network. Without it, nothing communicates—no browsing, no file sharing, no remote access.
Why IT and Cybersecurity Teams Care About IPs
Your IP address helps with:
-
Diagnosing connectivity issues
-
Setting up remote access
-
Configuring firewalls
-
Monitoring network activity
-
Detecting unauthorized devices
-
Enforcing security policies
Two Types of IP Addresses
There are two major types of IP addresses every professional should know.
1. Private (Internal) IP
Used inside your home or corporate network.
Examples:
-
192.168.x.x
-
10.x.x.x
2. Public (External) IP
Assigned by your ISP.
Identifies your network on the internet.
Knowing how to check both makes troubleshooting a lot easier.
How to Check IP Address in CMD (The Fastest Method)
Let’s start with the simplest answer to the question:
How to check IP address in CMD?
Use one command: ipconfig
Steps
-
Press Windows + R
-
Type cmd
-
Press Enter
-
Type:
-
Press Enter
You will see your IPv4 address, subnet mask, DNS, and default gateway.
What to Look For
Your IP address appears under:
IPv4 Address . . . . . : 192.168.x.x
Easy, right?
Understanding Each Detail in the ipconfig Output
The ipconfig results may look confusing at first, but they’re incredibly useful.
IPv4 Address
This is your internal IP.
Used for:
-
Device communication
-
Local network routing
-
Assigning permissions
Subnet Mask
Determines how large your network is.
Default Gateway
Usually the router’s IP—your “exit point” to the internet.
DNS Servers
Tells your device where to look when converting domain names to IPs.
CMD makes all of this visible instantly.
Advanced Ways to Check Your IP Address in CMD
While ipconfig is the most commonly used command, CMD includes many others that give deeper insights.
Using ipconfig /all for Full Network Details
For more complete information, run:
What This Shows
-
MAC address
-
DHCP status
-
Lease time
-
Full DNS information
-
Adapter manufacturer
-
Physical interface details
This is especially helpful for cybersecurity investigations and device audits.
Using getmac to View Network MAC Addresses
Your MAC address can be important for:
-
Device whitelisting
-
Security identification
-
Network inventory
Run:
Using tracert to Track Network Routes
tracert shows every hop your data takes to reach a server.
Helpful for diagnosing:
-
Latency issues
-
ISP problems
-
Misconfigured routers
Using ping to Test Connectivity
One of the simplest yet most powerful commands:
Useful for:
-
Verifying connection
-
Testing DNS
-
Measuring packet loss
Using netstat to Investigate Active Connections
Cybersecurity teams use netstat constantly.
Shows:
-
Open ports
-
Active connections
-
Listening services
-
Process IDs
This helps detect suspicious activity.
Finding Your Public (External) IP Address in CMD
Windows CMD doesn’t reveal your public IP by itself—but you can force it to using online query tools.
Use:
or:
(Works if curl is installed)
Your public IP is what websites and external networks see.
Common IP Address Issues and How to Fix Them
Let’s look at frequent network problems:
Issue: IP Address Conflict
Two devices sharing the same IP.
Fix:
Issue: “Media Disconnected” Error
Network interface is disabled.
Fix:
-
Enable Wi-Fi/Ethernet
-
Update network drivers
Issue: No Default Gateway
Often a router misconfiguration.
Fix:
-
Restart router
-
Manually reassign IP
Issue: DHCP Not Working
Device isn’t receiving an IP.
Fix:
-
Reconnect to network
-
Restart DHCP service
-
Assign static IP
How Knowing Your IP Helps IT Teams and Organizations
For IT managers and cybersecurity experts, checking an IP in CMD is just the beginning.
1. Easier Troubleshooting
A quick IP lookup helps determine:
-
Connection origin
-
DNS problems
-
Routing issues
-
Unauthorized access
2. Stronger Security Protocols
IP data supports:
-
Firewall rule creation
-
Network segmentation
-
Device authentication
3. Asset Tracking
Helps identify:
-
Rogue devices
-
Unapproved software
-
Suspicious behavior
4. Better Network Visibility
Understanding your devices’ IPs means understanding your network.
Best Practices for Working with IP Addresses in CMD
Use Command History
Press ↑ to repeat previous commands.
Run CMD as Administrator
Required for deeper diagnostics.
Use PowerShell for Advanced Scripts
PowerShell supports:
-
Automated network checks
-
IP scanning
-
Security audits
Document IP Changes
Especially in enterprise environments.
Frequently Asked Questions
1. Does CMD show both public and private IP addresses?
CMD shows your internal IP by default. Public IP requires a lookup command.
2. Can I change my IP address using CMD?
Yes—using:
3. Why is my PC showing a 169.x.x.x IP?
This means DHCP failed to assign an IP.
4. Is checking an IP address in CMD safe?
Yes. You’re only viewing information your system already uses.
5. Which CMD command shows full network details?
ipconfig /all shows every available detail.
Final Thoughts
Understanding how to check IP address in CMD gives you powerful insight into your device and network. Whether you’re diagnosing a connection issue, monitoring devices, securing a network, or simply learning how your system works, CMD provides the fastest and most reliable way to access IP information.
If you’re ready to streamline IT operations, enhance endpoint visibility, and improve overall device security, you can Start your free trial with ITarian to explore automated device management and advanced network monitoring tools that make your job easier.
