DEV Community

Cover image for  IP Addresses, An Intro for  Beginners
Akhand Patel
Akhand Patel

Posted on

IP Addresses, An Intro for Beginners

It may be near to impossible if you are reading this and have never came across the term IP address before. But for beginners it may be a bit difficult to understand them. In this blog, we would try to understand IP addresses and their types.

What is IP address?

As most of you may know, the major part of the modern internet uses a protocol called Internet Protocol(IP) to communicate with other hosts(computers) in the network. Yeah, that's where the IP part comes from in IP Address. The address part is a unique address to identify your device on the internet or local network. The internet needs a way to differentiate between all the devices and that's what the IP address is used for and hence is an integral part of the internet. The IP address is assigned by your ISP when you connect to the internet through them.

IP address representation

An IP address is a string of numbers and characters of fixed length separated by periods. IP address are not random but are assigned from a predetermined pool of strings.

Are IP address permanent?

Not really, they may change frequently your ISP may allocate you a new IP address whenever they feel so. Corporates!!! I feel you. But it may also change when you leave your home and connect to that Starbucks' Wi-Fi or any other network.

Why do we need IP?

The same reason you need a mobile number or a house address.
So that people can communicate with you easily. If you ant to search something on Google, then firstly your browser needs to know what's Google IP address, but then why do you need one? Because Google needs to know where to send the data back. The IP address allow you to be differentiated from billions of devices connected to the internet.


Types of IP addresses

  • Internet Protocol Version 4 address (IPV4)
  • Internet Protocol Version 6 address (IPV6)

The IPv4 Address

This was first defined in 1981 and is still the mostly used type of IP address. IPV4 address are 4 bytes(32 bits) long. Due to conventions or sake of readability, each single byte in the address also called an octet is written in dotted decimal representation. The dot separates each octet of address and each octet is written in decimal system. Let's take an example of IPV4 address
11000000.10101000.00000001.00000000
octets separated by dot
in decimal convention


 192.168.1.0 

Problems with IPV4

IPv4 has been around for a long time and so has humans. Humans multiply but ipv4 addresses don't. The format for IPv4 wasn’t designed to handle the sheer number of IP addresses. So we reached a point where the no. of devices connected to the internet was soon going to be more than all the ipv4 addresses(which are just 232 = 4,294,967,296). So we were running out of ipv4 address.

Solution to the Depleting Addresses

Researchers devised some strategies for the meantime like

  • Classless Inter Domain Routing (CIDR)
  • Private Address

But these were never intended as long term solutions. So finally researches came up with the new type of addresses called IPV6 addresses. Goodbye IPV4 and welcome IPV6 (not really though, we are going through a transitioning period both are currently in use)

IPV6 addresses

IPv6 was not just designed for today's need but for future needs also. The ipv4 supports approximately 4.3 billions addresses whereas ipv6 supports theoretically approximately 340 trillion, trillion, trillion addresses. So for the foreseeable future we may never run out of IP addresses. How does IPv6 support such a large no of addresses, well in place of using just 4 bytes (32 bits) as in ipv4 it uses 16 bytes (128 bits) for the string of addresses.

IPv6 is written in hexadecimal notation, separated into 8 groups of 16 bits by the colons. An IPv6 address representation looks like this:


2001:0db8:85a3:0000:0000:8a2e:0370:7334

What am I using currently?

Most probably you are allotted both type of addresses on your connection. It is worth noting that these protocols are not designed to be inter-operable, but certain technologies allow this interoperability. If you wish to know what's your IP address, you can go here


This is my second post here, it would be very helpful of you could provide a review or suggestion on this post. Thank you

Top comments (0)