What Is an IP Address and How Does It Work?
An IP address is a unique network identifier. Learn what an IP address is, how IPv4 and IPv6 differ, and how to find your public IP address instantly.
Dig Trace Team· Network Engineering Team8 min read
An IP address is a unique numerical label assigned to every device connected to a network. It works much like a street address, allowing data packets to find their way from a source to the correct destination across the internet or any private network. Without this identifier, routers wouldn't know where to deliver the emails, video streams, and API requests that cross the wire every second. If you've ever typed what is my IP address into a search engine, you were looking for the public address your internet provider assigned to your connection, the one the rest of the internet sees when your devices communicate.
What is an IP address?
Every smartphone, server, laptop, and IoT thermostat needs an IP address to send or receive traffic. The Internet Protocol defines these labels as structured numbers that identify both the network and the specific host on that network. The system is hierarchical so that large groups of devices can be managed without requiring every router to maintain a full map of the internet.
The most common version is IPv4. It uses a 32-bit address written as four decimal octets separated by dots, such as 192.0.2.1. This format yields roughly 4.3 billion unique addresses. That sounded like plenty in the early days of the internet, but by the 1990s engineers could see the supply wouldn't last.
IPv6 was developed to solve this. It uses 128-bit addresses written as eight groups of hexadecimal digits separated by colons, like 2001:db8::1, providing enough addresses for virtually unlimited growth. The scale is hard to grasp: 340 undecillion addresses means every device on the planet could have its own globally unique address without sharing through NAT.
Not every address is reachable from the open internet. Public IP addresses are globally routable and assigned by internet service providers. Private IP addresses, such as those in the 192.168.x.x, 10.x.x.x, and 172.16.x.x ranges, work only inside local networks. A home router typically hands out private addresses dynamically via DHCP. Meanwhile, the ISP assigns a single public address to the router itself. Some public addresses remain fixed as static IPs, which is useful for mail servers or VPN gateways. Most residential connections receive dynamic IPs that can shift when you reboot the modem or after a lease expires.
How does an IP address work?
Routers on the internet process millions of decisions every second. They do this by reading packet headers that contain a source IP address and a destination IP address, then forwarding each chunk toward the right network and device.
Without some form of grouping, every router would need a full map of the internet. IP addresses are split into a network portion and a host portion, with subnet masks or CIDR notation such as /24 telling routers which part identifies the network and which part identifies the specific machine. This grouping prevents routers from needing to memorize every individual device on the planet. Instead, they maintain smaller tables of network prefixes and pass the packet to the next hop.
On most home and office networks, many devices share a single public IP. The router performs Network Address Translation (NAT), swapping private addresses in outgoing packets for the router's public IP, then reversing the process for replies. This conserves the dwindling supply of IPv4 addresses and adds a basic layer of separation between internal devices and the open internet. It also means your laptop's 192.168.1.105 address is invisible to the wider web. When you need to know what address the world actually sees, tools like Digtrace's "What's My IP" tool or IP Checker display your current public address instantly.
Because humans remember names better than numbers, the Domain Name System (DNS) translates domain names into IP addresses. You can read more about that relationship in What Is DNS and How Does It Work. The two systems are inseparable. When you type a website into your browser, a DNS resolver first looks up the corresponding IP address so your computer can address the packet correctly.
IPv4 vs IPv6
By 2011, the last global IPv4 blocks had been allocated. Since then, network operators have relied on NAT and address trading to stretch the remaining supply. AWS's comparison of the two protocols notes that IPv6 eliminates the need for such conservation techniques entirely. The expanded space means every device can have its own globally unique address without sharing through NAT.
IPv4 global address exhaustion occurred in 2011. Today, organizations rely on NAT, IPv6 migration, or secondary markets to obtain additional IPv4 space.
The differences go beyond address space. IPv4 supports unicast, broadcast, and multicast traffic. IPv6 drops broadcast in favor of more efficient multicast and introduces anycast, which delivers traffic to the nearest of several possible receivers. This changes how networks handle discovery and redundancy.
IPv4 headers are variable-length and include a checksum. IPv6 uses a fixed 40-byte header plus optional extension headers and removes the checksum to speed up routing. IPv6 fragmentation is handled only at the source, not by intermediate routers. These changes reduce the processing burden on backbone equipment.
Configuration differs too. Most IPv4 networks rely on DHCP servers and NAT to assign addresses and share a public IP. IPv6 devices can often configure themselves automatically using SLAAC (Stateless Address Autoconfiguration), generating a working address without a central server. Privacy extensions in IPv6 even let devices rotate temporary addresses to reduce tracking over time.
How to find your IP address
Checking your local and public addresses is straightforward.
On Windows, open Command Prompt and run:
ipconfig
# Example output:
# Ethernet adapter Ethernet:
# IPv4 Address. . . . . . . . . . . : 192.168.1.105
# Subnet Mask . . . . . . . . . . . : 255.255.255.0
# Default Gateway . . . . . . . . . : 192.168.1.1On Linux and modern macOS systems, use the ip command:
ip addr show
# Example output:
# 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 ...
# inet 192.168.1.105/24 brd 192.168.1.255 scope global dynamic
# inet6 2001:db8::1/64 scope globalTo see the public address your ISP has assigned, visit a web-based tool. The Digtrace My IP page shows this immediately, while the IP Checker offers additional geolocation and network details. These tools are especially helpful when you're behind NAT and your local address doesn't match what remote servers see.
Why IP addressing matters today
Home users don't often think about IP addresses because NAT and dynamic assignment handle the details automatically. Yet these same mechanisms cause headaches for peer-to-peer gaming, self-hosted servers, or remote access. Those scenarios often need port forwarding or a static public IP to work reliably. If you've ever wondered why your console can't connect directly to a friend, NAT is usually the reason.
Ignoring IPv6 is becoming a risky bet. Major mobile networks and ISPs now push native IPv6 traffic past the 50 percent mark of all users, and new applications that lack IPv6 support risk becoming unreachable to a growing audience. Dual-stack operation, running IPv4 and IPv6 side by side, is the standard transition strategy today. Cloud providers now offer IPv6-only subnets and load balancers, with translation gateways available for legacy IPv4 clients. If you're building a service today, supporting both protocols isn't just future-proofing. It's necessary reachability.
Firewalls and intrusion detection systems must now watch two protocols at once. IPv6's massive address space makes exhaustive network scans impractical, but it also means monitoring tools must explicitly cover IPv6 to avoid blind spots. You can't secure what you can't see.
Each hop in a network path reveals an IP address that tells you which carrier currently handles your traffic. Tools like Traceroute and MTR map those hops, while a speed test helps determine whether the issue is latency, packet loss, or bandwidth. Together they turn abstract addresses into concrete diagnostic data.
Whether you're diagnosing a home network, building a cloud service, or securing enterprise infrastructure, IP addresses sit at the foundation of every connection on the internet. Knowing how IPv4 and IPv6 function, and how they interact with routing, NAT, and DNS, is essential literacy for anyone who works with networks. The transition from IPv4 to IPv6 is already past the halfway point. Networks, applications, and administrators that treat IPv6 as a first-class citizen are better prepared for the internet's next phase.