15.12.2 Why Do Computers Need IP Addresses?
- What Is an IP Address?
- Why Isn't a Device Name Enough?
- Why Can't Computers Use MAC Addresses?
- How Is an IP Address Different from a MAC Address?
- What Does "Hierarchical Addressing" Mean?
- How Do Routers Use IP Addresses?
- Why Are There Two Versions of IP?
- What Is Network Address Translation?
- How Does an IP Address Reach the Correct Computer?
- Will IPv4 Eventually Disappear?
- Why Are IP Addresses So Important?
- What Should You Remember?
Short Answer
Every device connected to the Internet requires an Internet Protocol (IP) address so that information can be delivered to the correct destination. An IP address acts much like a postal address, identifying both the network to which a device belongs and the device itself. Unlike hardware addresses, which operate only within a local network, IP addresses allow routers to forward packets across many interconnected networks, making worldwide communication possible.
What Is an IP Address?
An IP address is a unique logical identifier assigned to a device connected to an Internet Protocol (IP) network.
Whenever information is sent across the Internet, it is divided into small units called packets. Each packet contains both a source IP address and a destination IP address. These addresses tell the network where the packet originated and where it should ultimately be delivered.
Without IP addresses, routers would have no way of determining the destination of packets travelling across the Internet.
Why Isn't a Device Name Enough?
People usually identify computers by names rather than numbers.
For example, it is much easier to remember www.example.com than 93.184.216.34.
However, computer names are designed for people, not routers. A name can change, may exist in different languages, and can vary depending on the service being accessed. Routers require a simple, standardized method of identifying every destination. This is the role of the IP address.
Whenever a user enters a website address into a browser, the Domain Name System (DNS) translates that human-readable name into an IP address before communication begins.
Why Can't Computers Use MAC Addresses?
Every network interface also possesses a Media Access Control (MAC) address.
A MAC address uniquely identifies a particular network interface and is permanently associated with the hardware. MAC addresses work extremely well within a Local Area Network (LAN), but they have an important limitation—they provide no information about where the device is located within the wider Internet.
Consider a postal system. A person's name identifies who should receive a letter, but it does not indicate where they live. A postal address contains both the person's identity and their location within a structured delivery system.
Similarly, MAC addresses identify individual devices, but IP addresses identify both the device and its location within the Internet's addressing hierarchy.
How Is an IP Address Different from a MAC Address?
Although both are addresses, they perform different functions.
| MAC Address | IP Address |
|---|---|
| Hardware address | Logical network address |
| Used within a local network | Used between networks |
| Assigned to the network interface | Assigned by network configuration |
| Flat addressing structure | Hierarchical addressing structure |
| Used by switches | Used by routers |
The two addressing systems complement one another rather than compete.
A packet travelling across the Internet normally uses IP addresses for routing between networks and MAC addresses for delivery across each individual local network.
What Does "Hierarchical Addressing" Mean?
One of the most important characteristics of an IP address is that it contains two parts:
- a network identifier; and
- a host identifier.
The network identifier tells routers which network contains the destination. The host identifier identifies the individual device within that network. This hierarchy greatly simplifies routing.
Instead of maintaining routes to billions of individual computers, routers only need to know how to reach the destination network. Once the packet reaches that network, the local router delivers it to the appropriate host.
This principle allows the Internet to grow without overwhelming every router with enormous routing tables.
How Do Routers Use IP Addresses?
Every time a packet reaches a router, the router examines the destination IP address.
Using its routing table, the router determines which neighbouring router provides the best path toward the destination network. The packet is then forwarded to the next router. Each router repeats exactly the same process.
Although an Internet packet may pass through many routers before reaching its destination, each router only needs to make one simple decision: "Which neighbouring network should receive this packet next?"
This process continues until the packet finally arrives at the destination computer.
Why Are There Two Versions of IP?
The original Internet Protocol, known as IPv4, was developed during the early years of the Internet.
IPv4 uses 32-bit addresses, providing approximately 4.3 billion unique address combinations. When IPv4 was designed, this appeared to be an enormous number. However, the rapid growth of personal computers, smartphones, cloud computing, and the Internet of Things eventually exhausted the available address space.
To accommodate future growth, IPv6 was developed. IPv6 employs 128-bit addresses, providing an address space so large that it is effectively inexhaustible for the foreseeable future.
Although IPv4 and IPv6 use different address formats, they perform exactly the same function.
What Is Network Address Translation?
The shortage of IPv4 addresses led to the widespread adoption of Network Address Translation (NAT).
NAT allows many devices within a home or business network to share a single public IPv4 address. For example, a household may contain:
- laptops;
- smartphones;
- tablets;
- smart televisions;
- gaming consoles; and
- security cameras.
Internally, each device has its own private IP address. To the wider Internet, however, all of these devices appear to communicate through the single public IP address assigned to the household's broadband router.
This approach has greatly extended the useful life of IPv4.
How Does an IP Address Reach the Correct Computer?
Although routers forward packets using IP addresses, the final delivery within a local network requires MAC addresses.
When a packet reaches the destination network, the receiving router determines the appropriate MAC address corresponding to the destination IP address. The packet is then placed inside a local Ethernet or Wi-Fi frame and delivered to the correct device. This demonstrates how IP addressing and MAC addressing work together. IP addresses allow communication between networks.
MAC addresses allow communication within each network.
Will IPv4 Eventually Disappear?
For many years, engineers expected IPv6 to replace IPv4 rapidly.
In practice, the transition has been much slower. Today, both protocols continue to operate together. Many Internet services support both IPv4 and IPv6 simultaneously, allowing older and newer equipment to communicate without difficulty.
Over time, IPv6 will continue to become more common as Internet-connected devices increase in number, but IPv4 is likely to remain in use for many years.
Why Are IP Addresses So Important?
Without logical addressing, the Internet could never have grown beyond a collection of isolated local networks.
IP addressing provides the structure that allows routers to determine where information should travel while remaining independent of the underlying communication technology.
Whether a packet crosses:
- Ethernet;
- Wi-Fi;
- optical fiber;
- microwave radio;
- submarine cable; or
- satellite,
its IP address remains unchanged throughout the journey.
This separation between logical addressing and physical transmission has been one of the key factors in the success and scalability of the Internet.
What Should You Remember?
An IP address is much more than a number assigned to a computer.
It is the logical address that allows information to be delivered across millions of interconnected networks.
Unlike MAC addresses, which operate only within a local network, IP addresses provide a hierarchical addressing system that enables routers to forward packets efficiently across the global Internet.
Together with routing protocols, IP addressing forms one of the fundamental building blocks of modern digital communications and makes worldwide internetworking possible.
Back to reading