IPv4 addresses are often discussed through the older classful addressing system, and Class B remains one of the most recognized categories. Although modern networks usually rely on CIDR notation, understanding Class B IP addresses still helps administrators, students, and technical teams interpret legacy documentation, subnet plans, and address ranges.
TLDR: A Class B IP address has a first octet from 128 to 191 and uses the default subnet mask 255.255.0.0, also written as /16. In the original classful model, the first two octets identify the network, while the last two octets identify hosts. Class B networks were designed for medium to large organizations and can support up to 65,534 usable host addresses per network.
What Is a Class B IP Address?
A Class B IP address is part of the traditional IPv4 classful addressing structure. In this system, IPv4 addresses were divided into five classes: Class A, Class B, Class C, Class D, and Class E. Each class served a different purpose, with Class B positioned between very large Class A networks and smaller Class C networks.
Class B addresses were intended for organizations that needed more host capacity than a Class C network could provide, but did not require the enormous address space of a Class A network. Universities, large companies, government departments, and regional service providers historically made use of Class B networks.
In a Class B address, the first two octets represent the network portion, and the last two octets represent the host portion. For example, in the address 150.20.10.5, the network portion is 150.20, while 10.5 identifies a specific host within that network.
Class B IP Address Range
The Class B range is defined by the value of the first octet. A Class B IP address always begins with a number from 128 through 191.
- Starting range: 128.0.0.0
- Ending range: 191.255.255.255
- First octet range: 128 to 191
- Default CIDR prefix: /16
This means that any IPv4 address beginning with a first octet such as 130, 145, 172, or 190 falls within the Class B range under classful addressing rules. However, administrators should remember that modern allocation is not strictly class-based, so the real subnet size may be different when CIDR is used.
Default Subnet Mask for Class B
The default subnet mask for a Class B IP address is 255.255.0.0. In CIDR notation, this is written as /16.
This mask means that the first 16 bits are used for the network portion, and the remaining 16 bits are used for hosts. Since each IPv4 address has 32 bits in total, the structure looks like this:
- Network bits: 16
- Host bits: 16
- Subnet mask: 255.255.0.0
- CIDR notation: /16
With 16 host bits, a Class B network has 65,536 total addresses. Two addresses are reserved: one for the network address and one for the broadcast address. Therefore, a traditional Class B network provides 65,534 usable host addresses.
For example, the network 150.20.0.0/16 includes addresses from 150.20.0.0 to 150.20.255.255. The first address identifies the network, and the last address is the broadcast address. Usable host addresses range from 150.20.0.1 to 150.20.255.254.
Image not found in postmeta
Common Class B Examples
Several example IP addresses can illustrate how Class B addressing works:
- 128.10.5.20 — Class B because the first octet is 128.
- 150.25.100.8 — Class B because the first octet is 150.
- 172.16.1.10 — Class B and also part of the private IPv4 range.
- 191.200.30.45 — Class B because the first octet is 191.
A useful example is 172.16.0.0. Under classful rules, it falls in the Class B range because the first octet is 172. More importantly, the range from 172.16.0.0 to 172.31.255.255 is reserved for private networks. This private block is commonly used inside organizations, data centers, labs, and cloud environments.
Public and Private Class B Addresses
Not every Class B address is used the same way. Some Class B addresses are public, meaning they can be routed on the internet. Others are private, meaning they are reserved for internal networks and cannot be directly routed across the public internet.
The private Class B range is:
- 172.16.0.0 to 172.31.255.255
- CIDR block: 172.16.0.0/12
Although this private range begins with Class B-style addresses, it is technically defined today by CIDR as a /12 block. This is a good example of why classful terminology and modern CIDR notation can overlap but should not be treated as identical.
Why Class B Addressing Still Matters
Classful addressing is no longer the dominant method for designing IP networks. It was largely replaced by Classless Inter-Domain Routing, known as CIDR, because CIDR allows more flexible and efficient use of IPv4 space. Instead of being limited to fixed Class A, B, or C boundaries, networks can now use prefixes such as /20, /23, or /27.
Even so, Class B knowledge remains valuable. Many networking textbooks, certification materials, older systems, and troubleshooting guides still refer to Class B ranges and default masks. Recognizing that 172.20.5.10 is in the old Class B range, for instance, can help a technician understand why it may appear in internal enterprise networks.
Image not found in postmeta
Class B vs. Class A and Class C
Class B sits between Class A and Class C in terms of size. A Class A network uses a default mask of 255.0.0.0, while a Class C network uses 255.255.255.0. Class B uses 255.255.0.0, which provides a balanced number of networks and hosts.
- Class A: 1.0.0.0 to 126.255.255.255, default mask 255.0.0.0
- Class B: 128.0.0.0 to 191.255.255.255, default mask 255.255.0.0
- Class C: 192.0.0.0 to 223.255.255.255, default mask 255.255.255.0
This comparison shows why Class B was often selected for networks that needed many hosts but did not require millions of addresses.
FAQ
What is the range of Class B IP addresses?
The Class B range is 128.0.0.0 to 191.255.255.255. Any traditional classful IPv4 address with a first octet from 128 to 191 belongs to Class B.
What is the default subnet mask for Class B?
The default subnet mask for Class B is 255.255.0.0, which is also written as /16 in CIDR notation.
How many hosts can a Class B network support?
A traditional Class B network has 65,536 total addresses. After excluding the network and broadcast addresses, it supports 65,534 usable hosts.
Is 172.16.0.0 a Class B address?
Yes, under classful rules, 172.16.0.0 is in the Class B range. It is also part of the private IPv4 range 172.16.0.0 to 172.31.255.255.
Are Class B addresses still used today?
Class B terminology is still used in education, documentation, and troubleshooting. However, modern IP networks generally use CIDR rather than strict classful addressing.