News

News regarding leasing, buying or selling of IPv4 addresses.

Get in touch with us

What are the classes of IPv4? How to identify IP class?

  • Posted at 2022-04-29 18:15:44
  • By Prefixx Team

What are the classes of IPv4? How to identify IP class?

Just as a registration number is identified as a car, so does an IP address identify a device on the internet. IPv4 addressing is a concept that explains the addressing architecture of the internet. 
We tell you all you want to know about IPv4 addressing and the various classes of IPv4. We also tell you how to identify IP class through the IPv4 address.

The internet’s address architecture

An IP address has two parts – the network number and the host number. The IPv4 address itself is 32-bit long. The two parts together identify devices connected to the internet. Both the host address and the network address are essential.
 
While the host address could be sufficient in a LAN, networks need the network address for identification. Routers rely on the network address to ensure effective communication between hosts part of different networks. 

The 32-bit IP address is a binary number comprising 1’s and 0’s. The binary number can be grouped in octets (eight numbers each). When converted to decimal, it becomes an IP address expressed in dotted-decimal notation.

Example of dotted-decimal notation

Consider the example of an IP address that could be 
1001010000011110111010100010101

This number can be expressed as octets in the following form:
10010100 00011110 1110101 00010101

Now let’s convert each of the octet numbers from binary to decimal. This is how the result looks:
148 30 117 21

This is the IP address, which is expressed in dotted decimal notation as 148.30.117.21.

Class numbers

Considering the example given above, how do you identify the host number and network number from a given IP address? To make this easy, a system of classes was conceptualized to help identify the network and host numbers.
There were five different classes and the grouping was done based on the first few bits as per the first octet in the IP address.

As per this system, five classes are named:
1. Class A
2. Class B
3. Class C
4. Class D
5. Class E

Of these classes, Classes A, B, and C are the ones used to address hosts in an IP address. Class D addresses are used in multicasting. Class E addresses are mostly reserved for experiments. We need to know more about these classes, so we can understand how they identify the host and network numbers.

Class A addresses

Consider the first octet of the IP address. When the first number is 0, the address is called a Class A address. An address where the first octet value is from 0 to 127 is a Class A address. You must know that 0 and 127 themselves are reserved and cannot be a part of the network address. 

With one octet representing the network address, the rest is used for the host address. There are three octets remaining with 24 bits leaving 16,777,216 combinations or numbers. These two are reserved, leaving 16,777,214 host addresses.

So, it is clear that there are 126 Class A addresses each of which has nearly 17 million. Class A addresses are meant for a very large network. There are thus a handful of organizations that control most of the IP addresses on the internet.

Since one network cannot practically manage 65,000 hosts, subnets are used to ensure efficiency. Subnetting or subnet masks are 32-bit numbers where each bit in the mask corresponds to the counterpart in the IP address. The concept of subnets helps prevent IP address waste and ensures the logical organization of IP addresses.  

Class B addresses

In Class B addresses, 10 are the first two bits of the first octet. Where the address is in the first octet is from 128 to 191, the address is a Class B address. These addresses are for the use of medium-size organizations. The first 2 octets represent the network number and the remaining two octets the host number. Each Class B address can accommodate 65,534 hosts. 

Class C addresses

Class C addresses start with 110. When the IPv4 address is from 192 to 223 in the first octet, it is called a Class C address. These addresses are reserved for small networks. 
It must be known Class A and Class B addresses are nearly exhausted. That leaves only Class C left for new organizations needing IP addresses. 

The following depicts the number of networks and hosts for each class of networks.
• Class A has 127 possible networks (with 2 reserved) and 16,777,214 hosts for each network.
• Class B has 16,384 possible networks with 65,534 hosts per network.
• Class C has 2,097,152 possible networks where each network can have 254 hosts.

Class D addresses

These addresses are reserved for multicasting. They start with 1110 in the first octet. When the first octet is from 224 to 239, they are identifiable as Class D addresses. 

Class E addresses

The first octet in a Class E address starts from 1111. So, the range for Class E addresses is from 240 to 255. These addresses are not available for use. They are meant for experimental purposes.

How to identify IP class?

Using the above-mentioned architecture, it is easy to identify which class it belongs to. All you need to do is study the IPv4 address. Consider the first octet or the first eight bits. From this, note the starting number to determine the IPv4 class.
• When the address starts with 0, it’s a class A network.
• When it starts from 10, it is a class B network.
• When the address starts from 110, then it is class C.
• The address starting from 1110 is the class D network.
• If it starts from 1111, then it is a class D network.

Alternatively, you can consider the decimal-dotted depiction and use it to identify the class. The ranges can be used to identify Class A, B, and C networks. 

• When the first number in the IP address is 0 to 127, it is Class A.
• 129 to 191 is Class B.
• 192 to 223 in Class C.

Get more information Contact us to discuss your IPv4
needs today!

No hidden fees, free consult

Name

Company Name

Email

Phone Number

Inquiry Type

Message