Is MAC address same as IP address?

6 min
addresses on the internet

MAC and IP are acronyms you’ve probably come across quite a few times, especially when researching how computer networks work. These terms are often confused and misunderstood. In this article, we’ll sort out the difference between MAC address and IP address plain and clear. Let’s get to it!

First things first. MAC is not the same as IP. Both acronyms stand for telecommunication systems with addressing conventions, not addresses themselves.

MAC, IP, and protocol layers

A network protocol is a set of rules or standards which must be followed by devices in a network in order to communicate effectively. But one protocol to rule them all is not enough. It would have to be too elaborate to be practical, impossible to wholly understand by one person, and very tricky to implement. In real-life solutions, it’s important not to over-complicate things. Therefore, a range of protocols is in constant use on the Internet. They are organized into a hierarchical, layered structure. This bundle of protocols is called the Internet Protocol suite, also known as TCP/IP (Transmission Control Protocol/Internet Protocol), and has five layers:

  1. Physical layer.
  2. Link layer.
  3. Internet layer.
  4. Transport layer.
  5. Application layer.

The literature is not exactly consistent regarding what belongs to which layer, but this division helps to understand the principles. Here we’ll focus only on parts of layers 2 and 3. That’s where MAC (Medium Access Control) and IP (Internet Protocol) operate, respectively.

What is IP address and MAC address?

An address is a way to represent a location of a given plot of land. Messages in computer networks also need addresses. They always get delivered through several intermediate stages, at which they need to be forwarded in the right direction. So the destination (and usually the source) must obviously have their own addresses, much like on paper letters. Addresses on the web must also follow naming convention rules, just like towns, streets, and houses do in real life. But exactly what is the use of IP address and MAC address?

What we usually mean by a ‘network address’ is an IP address. It globally identifies interconnected entities such as servers, routers, PCs, or networks themselves. When your browser sends a request to fetch a website, it connects to the server a website lives on (for example, where Wikipedia is stored) based on its IP address and asks for a copy of the content to be sent your way. If your request is approved, appropriate content is sent back to the source address. This happens almost instantaneously while you wait for the site to load.

MAC addresses are important in local networks, where there are no routers between the source and destination computers. They both use mapping IP addresses to MAC addresses in order to direct messages correctly. The MAC address is typically assigned to a Network Interface Controller (a network card) by the manufacturer. That’s why it is also called a physical address or hardware address. It’s often impossible to change, written in read-only memory and identifying a device uniquely.

Let’s now specify what exactly those two addresses are and how they are represented. It’ll help to understand the IP vs MAC address comparison.

What is an IP address?

It’s a number assigned to an endpoint device in a computer network or the network itself. The term ‘IP address’ is often imprecisely abbreviated to ‘IP’. There are two distinct groups of IP addresses:

  • Public IPs are assigned on a global scale to identify a computer plugged to the Internet. Those addresses are managed by the Internet Assigned Numbers Authority (IANA).
  • Private IPs, which are allowed only within local networks. Those are always separate from each other. Private IPs are reused in different networks multiple times without conflicts.

IANA has assigned specific ranges of IP addresses to the regions of the world. Regional Internet Service Providers receive them to distribute among individual customers. That’s how an IP is connected to a geographical location. If you move around with a mobile device, it obtains a new IP address upon initiating a connection to every network. This is because IP addresses are not intended to be unchangeable. However, when there’s no need to change, many IPs aren’t altered for years. That’s for example the case with public IPs of home routers.

The prevalent Internet Protocol version 4 defines the addresses as 32-bit numbers. This is enough to number over 4 billion devices. The newer IP version 6 specifies addresses as 128-bit long. This corresponds to a truly unimaginable amount of addresses.

What is a MAC address?

It’s a unique 48-bit number assigned to a network card: a piece of hardware responsible for a computer’s online connection. It doesn’t depend on the type of network or geographical location. A single computer often has multiple MAC addresses, because it has several connectivity options. This convention allows numbering up to 248 pieces, which is over 281 trillion.

Mostly, the address is permanently fixed onto a piece of equipment. That’s why it is known as the physical address. The Institute of Electrical and Electronics Engineers (IEEE) supervises MAC address assignment. Manufacturers assign them to their products, and most times they shouldn’t or can’t be changed. However, many network interfaces allow such changes, for example, to construct a specific network architecture or to prevent online tracking. The number 248 is so big that the world will never run out of unique Mac addresses – there can never exist that many devices that will need them. Still, MAC addresses can sometimes be reused in separate, incompatible networks. There is also a 64-bit standard that allows over 65000 times more addresses.

MAC address vs IP address

When it comes to visual appearance, it’s easy to differentiate between IP address and MAC address. The most popular formats are as follows:

  • IPv4: 4 decimal numbers (of range 0-255) divided by dots, e.g.:
  • IPv6: 8 groups of 4 hexadecimal digits divided by colons, e.g.: 0123:4567:89ab:cdef:0123:4567:89ab:cdef.
  • MAC: 6 groups of 2 hexadecimal digits divided by dashes, e.g.: 01-35-79-ab-cd-ef.

These formats were introduced for human readability. For the machines, they are just binary. However, there are more differences between a MAC address and an IP address. Let’s compare them in a table.

MAC address IP address
Assigned to what?hardware – network cardsoftware network configuration
When assigned?typically once at equipment productionautomatically or manually at each connection setup
Active on which level?low, physical medium access levelhigher, network level
Address length48-bit32-bit in IPv4;128-bit in IPv6
Maximum amount of entities addressableover 281 trillionover 4 billion in IPv4;over 340 trillion trillion trillion in IPv6

The IPv4 has the shortest address, which is causing quite some trouble.

The still unsolved issue of address depletion

The IPv4 was standardized in the early 1980s. Back then, nobody dreamed of what the Internet would become. 4 billion different addresses available was more than enough. The reality proved incredible. Nowadays, billions of interconnected devices exist worldwide. Transition to IPv6 was anticipated since the early 2000s, but twenty years later it is still pending. How come?

Version 4 was so prevalent and people were so used to it that a very surprising thing happened. Everyone was trying to postpone moving to version 6! Even today, various methods are still in use to prevent the transition. Those include Network Address Translation (NAT), address recycling, and changes in worldwide assignments. Modern networks are prepared to adapt to IPv6, but they still rely mostly on an over-40-year-old standard. It’s far from optimal. Every trick uses up computing power and complicates the architecture. But it’s still better than paying the enormous costs of reconfiguring or replacing millions of fine-working devices. Depreciation of IPv4 will surely take years.

So old habits die hard, but a lesson has been learned. The new IPv6 standard allows so many addresses that they may be given away wastefully. To put things in perspective: the entire Earth could be covered with a densely-packed, mile-thick layer of microscopic contraptions with a different IPv6 address on each piece. And that craziness wouldn’t even use 1% of the address space.

How is network address & MAC address useful for me?

Computer networks are designed for maximum automation. You might never need to manipulate network addresses manually! That is if you’re an ordinary netizen, not an administrator. The MACs are an issue for equipment designers. Software engineers work more with IPs. Hardware and software that you use juggle them both constantly, but without you ever knowing. 

Still, it’s important to understand at least the basics of a system you’re using on a daily basis. The more you learn, the better decisions you can make. Let’s give an example.

Internet addressing (especially the IP) is used to track your location and your online activities. If you’re sensitive about your security and privacy, you might protect yourself by shielding your true IP when surfing the Web. There’s an easy way to do that with the help of a VPN. When you subscribe to and switch on a VPN service, your IP gets altered by the provider to one of his servers’ IPs. This way, many online tracking mechanisms get misled about your geographical location. Learn more about VPN uses and choose one for yourself!

BackNext article