What is the Range of IP Address

Table of Contents

Related Tutorials

Range of IP Address

The Internet Protocol version 4 (IPv4) is the fourth version of the Internet Protocol (IP) and the first extensively implemented version of the protocol. IP addresses (version 4) are 32-bit integers that may be written in hexadecimal format. The most common format is x.x.x.x, which is also known as dotted quad or dotted decimal. Each x is termed an octet since it is an 8-bit value. Therefore, in decimal notation, the range of x can be 0 to 255. For example, is a valid IPv4 address.

GYqJm5qHBhUcD2rni SUndtFs T wIlNh kP66uY1JFdquo6mUEdlkMM6e4U4pHH8GeV YbYix9odrtRE EG 0rzojDchdDHOU6TL nouiteEHdWfypEoZZ - What is the Range of IP Address

Fig 1: Structure of IPv4

Each router has a range of IP addresses that it may use. For instance, suppose a router’s IP address range is to As an outcome, there are a total of 201 IP addresses. However, the first IP (network IP) and the last IP (broadcast IP) are reserved. So,, the total number of IP addresses accessible is 199 for this router. 

Drawbacks of class-based IP addressing

All accessible IP addresses in the classful routing system are classified into distinct classes. As a result, an organization must utilize an IP address of class A, B, or C. Different types of classes, their range and number of host identifiers  are presented in the table below.

ClassRangeHost Identifiers
A10.0.0.0 — 16 million
B172.16.0.0 —,535
C192.168.0.0 — 254

When an organization needed more than 254 host Identifiers, this routing system would frequently fail.  Because,  the organization would now be classified as class B rather than class C. This indicates that the organization would utilize a class B license while having fewer than 65,535 hosts. That is, if an organization requires 535 IP addresses, it falls into class B. In this manner, the company will waste the remaining 65000 IP addresses, reducing the availability of IPv4 addresses needlessly. The Internet Engineering Task Force (IETF) created CIDR in 1993 to address this issue.

Classless Inter Domain Routing (CIDR)

CIDR, commonly known as supernetting, is a technique of allocating Internet Protocol (IP) addresses that enhances address distribution efficiency. The former system, which was based on Class A, Class B, and Class C networks, has been replaced by the CIDR scheme. This approach also aided in extending the life of IPv4 and reducing the size of routing tables.

Prefix and suffix are two sets of integers that make up CIDR IP addresses. The prefix denotes a network address (, while the suffix denotes the number of bits in the complete address (12). The slash(/) symbol separates the prefix and suffix. A CIDR IP address might look something like this when put together:

ApZR8Cleb00gNuaFNZUJ8nisWNoq50 N iEDF VXWIoyaG7MV2PF2NVwrfDhF0GswX7ApBawE9ab1zxJrGx8pzCu8dioJQBjU5Tl4q4dnSpWZBrRd iGnic3xnFQJ7W0MxpTc2pdvGLmkPIlVCRVERqTtP 3oyoxFcVPIKED WiZmNYf3FMV6r - What is the Range of IP Address

Fig 2: Structure of classless routing system

The CIDR system is used to define IP ranges. Its maximum value is 32, which corresponds to the number of bits in an IP address. In Fig 2, the value of CIDR is 32 . This indicates that there is only one IP address possible in this scenario. But when the value of CIDR is other than 32, then it refers to a range of IP. Now let’s see a few other examples.

IPRange – – –

There are 32 bits in each IP address x.x.x.x. We may deduce from the table that CIDR = 24 indicates that the first 24 bits are locked and the other 8 bits can freely choose any number from 0 to 255. So, when CIDR = 16, locked bits would be 16 and so on. So, the total number of IP addresses can be found from the equation given below.

no of IP address =232 – CIDR – 2

So, if CIDR = 16, total IP address would be 232-16 – 2 = 65534 . 

So far we have analyzed the CIDR which has a value of 2th power. Therefore, the question remains what would be the case if the value of CIDR is not 2th power such as 15 or 21. Let’s dig into one of these examples. 

Example 1:  For an IP / 22, find out the no of the IP address possible and IP address range. 


No of the IP address  = 232-22 -2= 1022 . 

In the problem here, CIDR = 22. Therefore, we may safely conclude that the first 16 bits of the 2 octet are locked. From here, we must convert the decimal value of IP to a binary number in order to approach the problem.

20uPdH5Tee KU0iQNUb3u48NDwJLx6bP3PcMXJOo2pZFwhAuVmqnlrAbae2vL9SR3n6SmcdnDFX8xnf9lAlCMLS0 eGkzgX0gWzZ8Hpf5TB0Cv9NdL6Kb4Wqs0QlaLI0lkbnb oBaUsJ1uO57K3BtkITr1inwprXIE6SVTfK nFZBGRizYCDnsP9 - What is the Range of IP Address

     Fig : Graphical presentation of the problem.

As a result, the first 22 bits are locked, leaving the remaining 10 bits free to accept any value they choose. The number of unlocked bits in the third octet is now two. As a conclusion, the minimum value of these 2 bits is 00 and the greatest value is 11.

Therefore, starting IP : 11000000 . 10101000 . 00001000 . 00000000

In decimal,                       192       .     156       .        8        .       0 

and, ending  IP :          11000000 . 10101000 . 00001011 . 11111111

In decimal,                        192      .     156       .        11      .     255 

Hence, the IP address range is to Because the first and final IP addresses are always reserved, the usable IP range is –

Example 2:   For an IP / 16, find out the no of the usable IP address and IP address range.


No of the IP address  = 232-16 -2= 65534 . 

So, here, CIDR = 16 that means the initial 16 bits are locked.

Hence, IP range: –

Usable IP range: –

For the readers’ convenience, some practice problems are provided below.

  • / 15
  • / 25
  • / 28
Share The Tutorial With Your Friends