Table of Contents
Historical View of IPv4: Classful Addressing
Classful addressing is an older way of organizing IPv4 addresses that shaped many modern concepts like default subnet masks, class A/B/C thinking, and traditional network design. While classful routing is no longer used on the public internet, understanding it makes later topics like CIDR and subnetting much clearer.
The Basic Idea of Address Classes
In classful addressing, the entire IPv4 space was divided into fixed blocks called classes. Each class had a fixed size network portion and a fixed size host portion. The class of an address was determined purely by the first few bits of the address, which also correspond to the first decimal number (the first octet).
IPv4 addresses are 32 bits, usually written as four decimal numbers separated by dots, for example 192.168.10.5. In classful addressing, the boundary between “network” bits and “host” bits was fixed based on the class, not chosen by the network designer.
The main classes used for unicast addressing were Class A, Class B, and Class C. There were also Class D and Class E for special purposes.
Class A, B, and C Address Ranges
Class A, B, and C are the core of classful addressing. Each class has a specific range, default subnet mask, and typical use case.
Class A
Class A networks were very large networks, usually assigned to large organizations or very early adopters of the internet.
You can recognize a Class A address by its first octet.
| Class | First bit pattern | First octet range | Default mask | Network bits | Host bits | Number of networks | Hosts per network (usable) |
|---|---|---|---|---|---|---|---|
| A | 0xxxxxxx | 0 to 127 | 255.0.0.0 | 8 | 24 | 128 | $2^{24} - 2$ |
In binary, a Class A address always starts with a leading 0 bit. That means the first octet is in the range 0 to 127.
The default subnet mask for Class A is 255.0.0.0, which means the first 8 bits (the first octet) represent the network, and the remaining 24 bits represent hosts in that network.
The number of possible host addresses in a Class A network is $2^{24}$, but 2 addresses (all zeros and all ones in the host part) are reserved for the network address and broadcast address. So the number of usable host addresses in one Class A network is:
Usable hosts per Class A network: $2^{24} - 2 = 16,777,214$
Only 126 of these Class A networks were actually usable for regular assignments (0.0.0.0 and 127.0.0.0 are reserved), so each one had an enormous number of possible hosts.
Class B
Class B networks are medium sized networks, originally thought suitable for universities and medium businesses.
| Class | First bit pattern | First octet range | Default mask | Network bits | Host bits | Number of networks | Hosts per network (usable) |
|---|---|---|---|---|---|---|---|
| B | 10xxxxxx | 128 to 191 | 255.255.0.0 | 16 | 16 | 16,384 | $2^{16} - 2$ |
The first two bits are 10, which makes the first octet between 128 and 191.
The default subnet mask is 255.255.0.0, so the first 16 bits (first two octets) represent the network, and the remaining 16 bits represent hosts.
The number of possible host addresses in a Class B network is $2^{16}$, minus 2 reserved addresses:
Usable hosts per Class B network: $2^{16} - 2 = 65,534$
Class B struck a balance between size and manageability, but still often wasted addresses because many organizations did not need that many hosts.
Class C
Class C networks are small networks. These were widely used in more modest environments such as small organizations.
| Class | First bit pattern | First octet range | Default mask | Network bits | Host bits | Number of networks | Hosts per network (usable) |
|---|---|---|---|---|---|---|---|
| C | 110xxxxx | 192 to 223 | 255.255.255.0 | 24 | 8 | 2,097,152 | $2^{8} - 2$ |
Class C addresses begin with 110 in binary in the first octet, giving a range from 192 to 223.
The default subnet mask is 255.255.255.0, so the first 24 bits (first three octets) represent the network, and the last 8 bits represent hosts.
The number of possible host addresses in a Class C network is $2^{8}$, minus 2 reserved:
Usable hosts per Class C network: $2^{8} - 2 = 254$
Class C allowed many more separate networks, but each one was relatively small.
Class D and Class E
Apart from the unicast classes A, B, and C, there were Class D and Class E, which are not used for normal host addressing.
| Class | First bit pattern | First octet range | Purpose |
|---|---|---|---|
| D | 1110xxxx | 224 to 239 | Multicast |
| E | 1111xxxx | 240 to 255 | Experimental |
Class D addresses, from 224.0.0.0 to 239.255.255.255, are used for multicast. They are not assigned to individual hosts in the same way as A, B, or C.
Class E addresses, from 240.0.0.0 to 255.255.255.255, were reserved for experimental and future use and are not normally used in production networks.
Determining the Class of an IPv4 Address
When looking at an IPv4 address, you can determine its class by examining the first octet. This does not involve the subnet mask. The simplest method is to remember the decimal ranges.
Class identification by first octet:
Class A: 0 to 127
Class B: 128 to 191
Class C: 192 to 223
Class D: 224 to 239
Class E: 240 to 255
Alternatively, you can look at the first bits of the address in binary.
For example, consider the address 10.15.200.7. The first octet is 10, which is between 0 and 127, so it is Class A.
As another example, 172.16.5.20 has a first octet of 172, which is between 128 and 191, so it is Class B.
Default Masks and Network / Host Split
In classful addressing, the subnet mask is implied by the address class. If you only see an address such as 192.168.1.10, without an explicit mask, the classful system would assume the default mask based on the class.
For each class you can think in terms of network bits and host bits.
| Class | Default mask | CIDR notation | Network bits | Host bits |
|---|---|---|---|---|
| A | 255.0.0.0 | /8 | 8 | 24 |
| B | 255.255.0.0 | /16 | 16 | 16 |
| C | 255.255.255.0 | /24 | 24 | 8 |
Although CIDR is a newer concept, it is helpful to write the default masks in CIDR form here. A Class A address corresponds to /8, Class B to /16, and Class C to /24.
The fixed network and host split was one of the defining features of classful addressing. It made router behavior simple but also very inflexible.
Address Wastage and Inefficiency
Classful addressing quickly showed serious problems in terms of address utilization.
Many organizations that received a Class A network did not need more than a small fraction of the 16 million possible host addresses they were given.
Organizations that needed a few thousand addresses often faced an awkward situation. A single Class C network was too small, with only 254 usable hosts, but a Class B network was far larger than needed, with over 65 thousand hosts. As a result, they often got a Class B and left most of it unused.
There were also cases where networks were built by combining many Class C networks to reach a desired size, which created complex routing tables and additional overhead.
The rigid boundaries between class A, B, and C prevented fine grained allocation of address space. This contributed to the rapid consumption of the IPv4 space at a global scale, even though much of it was actually unused.
Classful Routing Behavior
In a classful world, routers often did not carry subnet mask information with each route. Instead, they simply stored the network address and assumed the default mask based on the class.
This had several consequences.
If a router saw a route to 10.0.0.0, it would automatically treat it as a Class A network with a /8 mask. Similarly, 172.16.0.0 would be treated as a Class B network with a /16 mask.
Routers also believed that all subnets of the same classful network had to use the same subnet mask. This behavior is often described as disallowing Variable Length Subnet Masking inside one classful network. The same network could not mix different prefix lengths inside it, at least not in a way that the classful router would understand correctly.
This simplification made routing easy to implement early on, but it made networks larger and more wasteful, and it also prevented more advanced hierarchical designs.
The Role of Private Ranges in Classful Thinking
Private IPv4 ranges were defined later, but they follow the classful boundaries. While the concept of private versus public IP is covered elsewhere, it is worth noticing how the private blocks align with classes.
| Private block | Corresponding class | Default mask (classful) |
|---|---|---|
| 10.0.0.0/8 | Class A | 255.0.0.0 |
| 172.16.0.0/12 | Part of Class B | 255.255.0.0 (classful) |
| 192.168.0.0/16 | Part of Class C | 255.255.255.0 (classful) |
The 10.0.0.0 block is a single Class A network. Many people still speak informally of “a Class A private network” when they use 10.0.0.0 with its default mask.
The other two blocks are carved out of the larger Class B and Class C ranges, but are used with more flexible masks in practice.
This legacy connection to classful boundaries is one reason why class terminology still appears in conversation even after classful routing itself became obsolete.
Why Classful Addressing Was Abandoned
Classful addressing is primarily of historical interest today. It was replaced for several reasons.
First, the rigid structure caused immense address wastage. Large blocks were reserved and then underused. The design could not scale with the rapidly growing internet.
Second, classful routing tables grew large and complex. Routers could not summarize routes flexibly because they were forced to obey class boundaries. This increased memory and CPU requirements.
Third, network designers lacked control. They could not tailor subnet sizes to match real world needs. Every network of a given class had the same host capacity, which rarely matched exactly what was needed.
To solve these problems, two key techniques were introduced: Classless Inter Domain Routing and Variable Length Subnet Masking. These allow arbitrary network prefix lengths and fine grained control of address allocation. Those topics build directly on the limitations of classful addressing, so understanding this historical model makes the motivation for modern addressing much easier to follow.
Classful addressing still appears in default mask values and in casual terms such as “Class C sized network,” but on the public internet, routing today is classless.